Returns the artifacts Resource.
cancel(name, body=None, x__xgafv=None)
Deprecated: use `CancelTaskLro` instead. This method keeps the same cancellation semantics but returns `Task` directly, which forecloses the future cascade behaviour on recurring parents that only an `Operation` return type can express. Cancels a task, out-of-band by id. Drains any in-progress work and moves the task to CANCELLED. Use this when there is no active stream (e.g. a scheduled or background task) or when a caller other than the streaming client cancels. A task may also be cancelled in-band via the bidi cancel_task end_request; the two paths are equivalent. Cancellation semantics: * Idempotent: cancelling an already-terminal task is a no-op that returns the current Task; concurrent/duplicate cancels collapse to one CANCELLED. * First terminal state wins: once the task is CANCELLED/COMPLETED/FAILED, later cancels have no effect. * Cancel takes precedence over complete_task: a cancel arriving while (or after) a client half-closes with complete_task still drives the task to CANCELLED rather than letting it finish.
Close httplib2 connections.
Creates a task without opening a live channel. Convenient for scheduled/background tasks where the caller does not need to drive the execution interactively; observe progress later via StreamTask (or by reconnecting to CreateTaskBidiStream with a `subscribe_task` request).
delete(name, operateOnSelf=None, x__xgafv=None)
Deletes a task. Long-running because deletion cascades: it cancels any active run (WORKING / REQUIRES_ACTION / SUSPENDED tasks are cancelled-then-deleted, not rejected), and cleans up the task's bound resources -- environment, generated artifacts, and the runtime trajectory/sessions. The operation completes when the cascade finishes; on success the response is google.protobuf.Empty.
deleteArtifact(task, body=None, x__xgafv=None)
Deletes a file from a task's workspace. `path` must be an absolute path to a file under `/workspace/userdata/` (for example, `/workspace/userdata/input.csv`). Paths outside `/workspace/userdata/`, `/workspace/userdata` itself, relative paths, or paths with `.` or `..` segments fail with `INVALID_ARGUMENT`. Directory paths and tasks in a terminal state fail with `FAILED_PRECONDITION`. A missing file fails with `NOT_FOUND` unless `allow_missing` is true, in which case the call succeeds with an empty response.
download(name, path=None, processingConfig_outputMimeType=None, x__xgafv=None)
Downloads a file. The response body is the file's bytes, with the file's own media type as the `Content-Type` and a `Content-Disposition` that names the file. Media is the default and only representation, so no `alt` parameter is needed. A preview sets `processing_config` and gets a rendition of the file in place of the file, such as a PDF of a .pptx: the response body is the rendition, with its own media type as the `Content-Type` and a `Content-Disposition` name that ends in its extension. Without `processing_config` the response is always the stored file.
downloadArtifact(task, path=None, processingConfig_outputMimeType=None, x__xgafv=None)
Downloads a file from a task's workspace as a stream of chunks. A server-streaming RPC. The response body is the file's raw bytes, with the file's own media type as the `Content-Type`. At most 1 GiB. Like ListTaskArtifacts, reads from the running sandbox when there is one, so a file the agent has just written is returned even before it reaches storage.
download_media(name, path=None, processingConfig_outputMimeType=None, x__xgafv=None)
Downloads a file. The response body is the file's bytes, with the file's own media type as the `Content-Type` and a `Content-Disposition` that names the file. Media is the default and only representation, so no `alt` parameter is needed. A preview sets `processing_config` and gets a rendition of the file in place of the file, such as a PDF of a .pptx: the response body is the rendition, with its own media type as the `Content-Type` and a `Content-Disposition` name that ends in its extension. Without `processing_config` the response is always the stored file.
Gets a task.
list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, x__xgafv=None)
Lists tasks under a parent. Supports filtering (e.g. by status or assigned_agent) so a surface can show "my tasks".
listArtifacts(task, pageSize=None, pageToken=None, path=None, recursive=None, x__xgafv=None)
Lists the files in a task's workspace. By default only the immediate children of `path` are returned; set `recursive` to descend into subdirectories. Entries are returned in breadth-first order. While the task's sandbox is running, paths it writes locally are read from the sandbox so the listing reflects files not yet synced to storage; otherwise they are read from storage. Which one served a request is not visible to the caller.
listArtifacts_next(previous_request, previous_response)
Retrieves the next page of results.
list_next(previous_request, previous_response)
Retrieves the next page of results.
patch(name, body=None, updateMask=None, x__xgafv=None)
Updates a task's mutable fields (e.g. schedule, priority, title). Typically allowed while the task is IDLE.
resume(name, body=None, x__xgafv=None)
Resumes a suspended task, transitioning it back to an active state (WORKING or QUEUED).
stream(name, continuationToken=None, nextStepSeqNum=None, snapshot=None, x__xgafv=None)
Read-only server-stream of a task's execution by id: trajectory steps and status changes, resumable from a step sequence number. Unlike CreateTaskBidiStream, it does not accept client inputs -- use it to observe or replay a task (the trajectory is not stored on the Task resource). This is the entry point for *observers*: it tails the trajectory from interaction storage without restoring the runtime actor, so it adds no restore latency and continues to follow output that a participant driving the task on a CreateTaskBidiStream connection produces. Observe-only clients should prefer this over a subscribe_task connect on CreateTaskBidiStream, which restores the actor and is meant for clients that will send input.
suspend(name, body=None, x__xgafv=None)
Suspends a task, pausing its active turn or scheduling loop and transitioning the status to SUSPENDED. The underlying runtime session remains resumable.
upload(name, body=None, media_body=None, media_mime_type=None, x__xgafv=None)
Uploads a file. The file is sent as media: post it to this method's URL with an `/upload` prefix, e.g. `/upload/v1beta1/{name}:upload`, carrying `path` as request metadata and the file's bytes as the media content. The task must not be in a terminal state, and an existing file at `path` is replaced. At most 10 GiB.
uploadArtifact(task, body=None, path=None, x__xgafv=None)
Uploads a file into a task's workspace. A client-streaming RPC: the request body is the file's raw bytes, relayed to storage a chunk at a time, so neither ESF nor this server holds the whole file. A broken connection restarts the upload from zero. `path` must be an absolute path under `/workspace/userdata/`. The task must not be in a terminal state. An existing file at `path` is replaced. At most 1 GiB.
cancel(name, body=None, x__xgafv=None)
Deprecated: use `CancelTaskLro` instead. This method keeps the same cancellation semantics but returns `Task` directly, which forecloses the future cascade behaviour on recurring parents that only an `Operation` return type can express. Cancels a task, out-of-band by id. Drains any in-progress work and moves the task to CANCELLED. Use this when there is no active stream (e.g. a scheduled or background task) or when a caller other than the streaming client cancels. A task may also be cancelled in-band via the bidi cancel_task end_request; the two paths are equivalent. Cancellation semantics: * Idempotent: cancelling an already-terminal task is a no-op that returns the current Task; concurrent/duplicate cancels collapse to one CANCELLED. * First terminal state wins: once the task is CANCELLED/COMPLETED/FAILED, later cancels have no effect. * Cancel takes precedence over complete_task: a cancel arriving while (or after) a client half-closes with complete_task still drives the task to CANCELLED rather than letting it finish.
Args:
name: string, Required. The name of the task to cancel. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
body: object, The request body.
The object takes the form of:
{ # Request for TaskService.CancelTask.
"operateOnSelf": True or False, # Optional. Whether to skip cascading cancellation to all descendant subtasks. Defaults to false (cascades to all descendants by default). Matches google.cloud.aiplatform.master.SuspendTaskRequest.operate_on_self. Behavior for CancelTaskLro (cascade semantics do not apply to the deprecated sync CancelTask method, which is always self-only): UNSET or false ⇒ cascade to non-terminal descendants (gated by Mendel flag sobi_enable_cascading_cancel_task; returns FAILED_PRECONDITION when the flag is OFF and the task has non-terminal children). true ⇒ cancel this task only.
}
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
close()
Close httplib2 connections.
create(parent, body=None, uniqueCreationToken=None, userContext_channel=None, userContext_location=None, userContext_timeZone=None, x__xgafv=None)
Creates a task without opening a live channel. Convenient for scheduled/background tasks where the caller does not need to drive the execution interactively; observe progress later via StreamTask (or by reconnecting to CreateTaskBidiStream with a `subscribe_task` request).
Args:
parent: string, Required. The parent agent that owns this task. Format: projects/{project}/locations/{location}/agents/{agent} (required)
body: object, The request body.
The object takes the form of:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
uniqueCreationToken: string, Optional. Optional idempotency token to guarantee the task is created only once. Suggest a UUID. A create carrying a token that a live task of the same agent already holds fails with `ALREADY_EXISTS`, naming that task in the response. The token is free again once that task finishes.
userContext_channel: string, Optional. How the user's input reached the agent. Leave unset when the user talks to the agent directly in an AI-native interface.
Allowed values
CHANNEL_UNSPECIFIED - Default. The user is talking to the agent directly in an AI-native interface (e.g. the Gemini Enterprise app, Workspace Studio, or the Gemini app), or the channel is unknown. The agent applies no channel-specific behavior.
CHAT - A threaded conversation on a communication product where the agent is one participant, e.g. a Google Chat DM or space, or a comment thread on a document. The agent keeps its reply short and conversational, suited to a thread that others can read, and may ask a follow-up question.
EMAIL - An email message. The agent writes a complete, self-contained reply suited to email, and avoids follow-up questions it could anticipate, since each round trip is slow.
userContext_location: string, Optional. The user's coarse, human-readable location, e.g. "Mountain View, CA, US". Must be no more precise than city level; never send street addresses, postal codes, or coordinates. The agent uses it for location-dependent requests, e.g. weather or nearby places.
userContext_timeZone: string, Optional. The user's IANA time zone name, e.g. "America/Los_Angeles". The agent uses it to interpret and present dates and times, e.g. to resolve "tomorrow morning".
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
delete(name, operateOnSelf=None, x__xgafv=None)
Deletes a task. Long-running because deletion cascades: it cancels any active run (WORKING / REQUIRES_ACTION / SUSPENDED tasks are cancelled-then-deleted, not rejected), and cleans up the task's bound resources -- environment, generated artifacts, and the runtime trajectory/sessions. The operation completes when the cascade finishes; on success the response is google.protobuf.Empty.
Args:
name: string, Required. The name of the task to delete. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
operateOnSelf: boolean, Optional. Whether to skip cascading deletion to all descendant subtasks. Defaults to false (cascades to all descendants by default). Matches google.cloud.aiplatform.master.CancelTaskRequest.operate_on_self. Behavior: UNSET or false ⇒ cascade: delete this task and every non-terminal descendant (gated by Mendel flag sobi_enable_cascading_delete_task; returns FAILED_PRECONDITION when the flag is OFF and the task has non-terminal children). true ⇒ delete this task only. Each descendant deletion signals the runtime for the live-session case (Actor.OnCancel finalizes trajectory + reclaims sandbox VM) before removing the Sobi DB rows, matching the single-DeleteTask contract.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # This resource represents a long-running operation that is the result of a network API call.
"done": True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
"metadata": { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
"name": "A String", # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
"response": { # The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
}
deleteArtifact(task, body=None, x__xgafv=None)
Deletes a file from a task's workspace. `path` must be an absolute path to a file under `/workspace/userdata/` (for example, `/workspace/userdata/input.csv`). Paths outside `/workspace/userdata/`, `/workspace/userdata` itself, relative paths, or paths with `.` or `..` segments fail with `INVALID_ARGUMENT`. Directory paths and tasks in a terminal state fail with `FAILED_PRECONDITION`. A missing file fails with `NOT_FOUND` unless `allow_missing` is true, in which case the call succeeds with an empty response.
Args:
task: string, Required. The task to delete from. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
body: object, The request body.
The object takes the form of:
{ # Request for TaskService.DeleteTaskArtifact.
"allowMissing": True or False, # Optional. If set to true, and the file is not found, the request will succeed without error.
"path": "A String", # Required. Absolute path of the file to delete, e.g. "/workspace/userdata/input.csv". Must be under "/workspace/userdata/", at most 1024 characters, and not contain a ".." segment.
}
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Response for TaskService.DeleteTaskArtifact.
}
download(name, path=None, processingConfig_outputMimeType=None, x__xgafv=None)
Downloads a file. The response body is the file's bytes, with the file's own media type as the `Content-Type` and a `Content-Disposition` that names the file. Media is the default and only representation, so no `alt` parameter is needed. A preview sets `processing_config` and gets a rendition of the file in place of the file, such as a PDF of a .pptx: the response body is the rendition, with its own media type as the `Content-Type` and a `Content-Disposition` name that ends in its extension. Without `processing_config` the response is always the stored file.
Args:
name: string, Required. The task or collaborative project to download from. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} or projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project} (required)
path: string, Required. Absolute path of a file in the task's workspace, e.g. `/workspace/report.md`, or, for a collaborative project, under `/workspace/project`, e.g. `/workspace/project/report.md`. Must be under `/workspace`, at most 1024 characters, and not contain a `..` segment. Accepts `TaskArtifactFile.path` as-is.
processingConfig_outputMimeType: string, Required. The media type of the rendition: * `application/pdf`: the file as a PDF, e.g. of a .docx, .pptx or .xlsx. * `application/json`: a spreadsheet, e.g. a .xlsx or .csv, as JSON describing its sheets and cells, from which a client draws the workbook as a grid. Any other value fails with `INVALID_ARGUMENT`.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A reference to data stored on the filesystem, on GFS or in blobstore.
"algorithm": "A String", # Deprecated, use one of explicit hash type fields instead. Algorithm used for calculating the hash. As of 2011/01/21, "MD5" is the only possible value for this field. New values may be added at any time.
"bigstoreObjectRef": "A String", # Use object_id instead.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"compositeMedia": [ # A composite media composed of one or more media objects, set if reference_type is COMPOSITE_MEDIA. The media length field must be set to the sum of the lengths of all composite media objects. Note: All composite media must have length specified.
{ # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
],
"contentType": "A String", # MIME type of the data
"contentTypeInfo": { # Detailed Content-Type information from Scotty. The Content-Type of the media will typically be filled in by the header or Scotty's best_guess, but this extended information provides the backend with more information so that it can make a better decision if needed. This is only used on media upload requests from Scotty. # Extended content type information provided for Scotty uploads.
"bestGuess": "A String", # Scotty's best guess of what the content type of the file is.
"fromBytes": "A String", # The content type of the file derived by looking at specific bytes (i.e. "magic bytes") of the actual file.
"fromFileName": "A String", # The content type of the file derived from the file extension of the original file name used by the client.
"fromFusionId": "A String", # The content type of the file detected by Fusion ID. go/fusionid
"fromHeader": "A String", # The content type of the file as specified in the request headers, multipart headers, or RUPIO start request.
"fromUrlPath": "A String", # The content type of the file derived from the file extension of the URL path. The URL path is assumed to represent a file name (which is typically only true for agents that are providing a REST API).
"fusionIdDetectionMetadata": "A String", # Metadata information from Fusion ID detection. Serialized FusionIdDetectionMetadata proto. Only set if from_fusion_id is set.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # For Scotty Uploads: Scotty-provided hashes for uploads For Scotty Downloads: (WARNING: DO NOT USE WITHOUT PERMISSION FROM THE SCOTTY TEAM.) A Hash provided by the agent to be used to verify the data being downloaded. Currently only supported for inline payloads. Further, only crc32c_hash is currently supported.
"diffChecksumsResponse": { # Backend response for a Diff get checksums response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. # Set if reference_type is DIFF_CHECKSUMS_RESPONSE.
"checksumsLocation": { # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. # Exactly one of these fields must be populated. If checksums_location is filled, the server will return the corresponding contents to the user. If object_location is filled, the server will calculate the checksums based on the content there and return that to the user. For details on the format of the checksums, see http://go/scotty-diff-protocol.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
"chunkSizeBytes": "A String", # The chunk size of checksums. Must be a multiple of 256KB.
"objectLocation": { # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. # If set, calculate the checksums based on the contents and return them to the caller.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
"objectSizeBytes": "A String", # The total size of the server object.
"objectVersion": "A String", # The object version of the object the checksums are being returned for.
},
"diffDownloadResponse": { # Backend response for a Diff download response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. # Set if reference_type is DIFF_DOWNLOAD_RESPONSE.
"objectLocation": { # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. # The original object location.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
},
"diffUploadRequest": { # A Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. # Set if reference_type is DIFF_UPLOAD_REQUEST.
"checksumsInfo": { # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. # The location of the checksums for the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received. For details on the format of the checksums, see http://go/scotty-diff-protocol.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
"objectInfo": { # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. # The location of the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
"objectVersion": "A String", # The object version of the object that is the base version the incoming diff script will be applied to. This field will always be filled in.
},
"diffUploadResponse": { # Backend response for a Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. # Set if reference_type is DIFF_UPLOAD_RESPONSE.
"objectVersion": "A String", # The object version of the object at the server. Must be included in the end notification response. The version in the end notification response must correspond to the new version of the object that is now stored at the server, after the upload.
"originalObject": { # A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. # The location of the original file for a diff upload request. Must be filled in if responding to an upload start notification.
"blobRef": "A String", # Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.
"blobstore2Info": { # Information to read/write to blobstore2. # Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob.
"blobGeneration": "A String", # The blob generation id.
"blobId": "A String", # The blob id, e.g., /blobstore/prod/playground/scotty
"downloadExternalReadToken": "A String", # A serialized External Read Token passed from Bigstore -> Scotty for a GCS download. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"downloadReadHandle": "A String", # Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.
"readToken": "A String", # The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.
"uploadFragmentListCreationInfo": "A String", # A serialized Object Fragment List Creation Info passed from Bigstore -> Scotty for a GCS upload. This field must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
"uploadMetadataContainer": "A String", # Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.
},
"cosmoBinaryReference": "A String", # A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.
"crc32cHash": 42, # crc32.c hash for the payload.
"inline": "A String", # Media data, set if reference_type is INLINE
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # MD5 hash for the payload.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # SHA-1 hash for the payload.
},
},
"diffVersionResponse": { # Backend response for a Diff get version response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. # Set if reference_type is DIFF_VERSION_RESPONSE.
"objectSizeBytes": "A String", # The total size of the server object.
"objectVersion": "A String", # The version of the object stored at the server.
},
"downloadParameters": { # Parameters specific to media downloads. # Parameters for a media download.
"allowGzipCompression": True or False, # A boolean to be returned in the response to Scotty. Allows/disallows gzip encoding of the payload content when the server thinks it's advantageous (hence, does not guarantee compression) which allows Scotty to GZip the response to the client.
"ignoreRange": True or False, # Determining whether or not Apiary should skip the inclusion of any Content-Range header on its response to Scotty.
},
"filename": "A String", # Original file name
"hash": "A String", # Deprecated, use one of explicit hash type fields instead. These two hash related fields will only be populated on Scotty based media uploads and will contain the content of the hash group in the NotificationRequest: http://cs/#google3/blobstore2/api/scotty/service/proto/upload_listener.proto&q=class:Hash Hex encoded hash value of the uploaded media.
"hashVerified": True or False, # For Scotty uploads only. If a user sends a hash code and the backend has requested that Scotty verify the upload against the client hash, Scotty will perform the check on behalf of the backend and will reject it if the hashes don't match. This is set to true if Scotty performed this verification.
"inline": "A String", # Media data, set if reference_type is INLINE
"isPotentialRetry": True or False, # |is_potential_retry| is set false only when Scotty is certain that it has not sent the request before. When a client resumes an upload, this field must be set true in agent calls, because Scotty cannot be certain that it has never sent the request before due to potential failure in the session state persistence.
"length": "A String", # Size of the data, in bytes
"md5Hash": "A String", # Scotty-provided MD5 hash for an upload.
"mediaId": "A String", # Media id to forward to the operation GetMedia. Can be set if reference_type is GET_MEDIA.
"objectId": { # This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. # Reference to a TI Blob, set if reference_type is BIGSTORE_REF.
"bucketName": "A String", # The name of the bucket to which this object belongs.
"generation": "A String", # Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions
"objectName": "A String", # The name of the object.
},
"path": "A String", # Path to the data, set if reference_type is PATH
"referenceType": "A String", # Describes what the field reference contains.
"sha1Hash": "A String", # Scotty-provided SHA1 hash for an upload.
"sha256Hash": "A String", # Scotty-provided SHA256 hash for an upload.
"sha512Hash": "A String", # Scotty-provided SHA512 hash for an upload.
"timestamp": "A String", # Time at which the media data was last updated, in milliseconds since UNIX epoch
"token": "A String", # A unique fingerprint/version id for the media data
}
downloadArtifact(task, path=None, processingConfig_outputMimeType=None, x__xgafv=None)
Downloads a file from a task's workspace as a stream of chunks. A server-streaming RPC. The response body is the file's raw bytes, with the file's own media type as the `Content-Type`. At most 1 GiB. Like ListTaskArtifacts, reads from the running sandbox when there is one, so a file the agent has just written is returned even before it reaches storage.
Args:
task: string, Required. The task to download from. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
path: string, Required. Absolute path of the file to read, e.g. "/workspace/report.md". Must be under "/workspace", at most 1024 characters, and not contain a ".." segment.
processingConfig_outputMimeType: string, Required. The media type to return: * `application/pdf`: the file as a PDF, e.g. a .docx or .pptx. * `application/json`: a spreadsheet, e.g. a .xlsx, as JSON describing its sheets and cells, from which a client draws the workbook as a grid. Any other value fails with `INVALID_ARGUMENT`.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Message that represents an arbitrary HTTP body. It should only be used for payload formats that can't be represented as JSON, such as raw binary or an HTML page. This message can be used both in streaming and non-streaming API methods in the request as well as the response. It can be used as a top-level request field, which is convenient if one wants to extract parameters from either the URL or HTTP template into the request fields and also want access to the raw HTTP body. Example: message GetResourceRequest { // A unique request id. string request_id = 1; // The raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } service ResourceService { rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); } Example with streaming methods: service CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); } Use of this type only changes how the request and response bodies are handled, all other features will continue to work unchanged.
"contentType": "A String", # The HTTP Content-Type header value specifying the content type of the body.
"data": "A String", # The HTTP request/response body as raw binary.
"extensions": [ # Application specific response metadata. Must be set in the first response for streaming APIs.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
}
download_media(name, path=None, processingConfig_outputMimeType=None, x__xgafv=None)
Downloads a file. The response body is the file's bytes, with the file's own media type as the `Content-Type` and a `Content-Disposition` that names the file. Media is the default and only representation, so no `alt` parameter is needed. A preview sets `processing_config` and gets a rendition of the file in place of the file, such as a PDF of a .pptx: the response body is the rendition, with its own media type as the `Content-Type` and a `Content-Disposition` name that ends in its extension. Without `processing_config` the response is always the stored file.
Args:
name: string, Required. The task or collaborative project to download from. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} or projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project} (required)
path: string, Required. Absolute path of a file in the task's workspace, e.g. `/workspace/report.md`, or, for a collaborative project, under `/workspace/project`, e.g. `/workspace/project/report.md`. Must be under `/workspace`, at most 1024 characters, and not contain a `..` segment. Accepts `TaskArtifactFile.path` as-is.
processingConfig_outputMimeType: string, Required. The media type of the rendition: * `application/pdf`: the file as a PDF, e.g. of a .docx, .pptx or .xlsx. * `application/json`: a spreadsheet, e.g. a .xlsx or .csv, as JSON describing its sheets and cells, from which a client draws the workbook as a grid. Any other value fails with `INVALID_ARGUMENT`.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
The media object as a string.
get(name, x__xgafv=None)
Gets a task.
Args:
name: string, Required. The name of the task to retrieve. Both name forms are accepted: * projects/{project}/locations/{location}/agents/{agent}/tasks/{task} * projects/{project}/locations/{location}/tasks/{task} (required)
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, x__xgafv=None)
Lists tasks under a parent. Supports filtering (e.g. by status or assigned_agent) so a surface can show "my tasks".
Args:
parent: string, Required. The parent to list tasks under. Both forms are accepted and scope the listing differently: * projects/{project}/locations/{location}/agents/{agent} -- tasks assigned to that agent. * projects/{project}/locations/{location} -- all tasks in the location. (required)
filter: string, Optional. A filter expression, e.g. "status=WORKING". Lineage filters pick how much of a task tree to fetch: * "parent_task_id=" -- direct children only (progressive disclosure, one level per call). * "root_task_id=" -- the whole tree in one flat collection. Label filters support filtering by task labels: * "labels.=" -- match tasks with the given label key and value. Multiple label filters can be combined with AND. Multiple values for the same key can be combined with OR, e.g., "labels.foo=bar OR labels.foo=baz". Status filters restrict the listing to tasks in the given statuses: * "status=" -- e.g. "status=WORKING". Multiple statuses can be combined with OR, e.g., "status=WORKING OR status=IDLE". Both page normally via `page_size`/`page_token`, and both are ordered by `order_by` (default "create_time desc"), not by tree shape. A whole-tree page is therefore not a subtree: a child can arrive before its parent, so the client buffers by `parent_task_id` and renders as parents resolve.
orderBy: string, Optional. Sort order, e.g. "create_time desc". The sortable fields are `create_time` and `update_time`. Defaults to "create_time desc".
pageSize: integer, Optional. The maximum number of tasks to return. The service may return fewer. If unspecified (or <= 0), at most 50 are returned. The maximum is 100; larger values are capped to 100.
pageToken: string, Optional. A page token from a previous ListTasks call.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Response for TaskService.ListTasks.
"nextPageToken": "A String", # A token to retrieve the next page; empty if there are no more pages.
"tasks": [ # The tasks from the requested collection.
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
},
],
}
listArtifacts(task, pageSize=None, pageToken=None, path=None, recursive=None, x__xgafv=None)
Lists the files in a task's workspace. By default only the immediate children of `path` are returned; set `recursive` to descend into subdirectories. Entries are returned in breadth-first order. While the task's sandbox is running, paths it writes locally are read from the sandbox so the listing reflects files not yet synced to storage; otherwise they are read from storage. Which one served a request is not visible to the caller.
Args:
task: string, Required. The task whose workspace to list. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
pageSize: integer, Optional. The maximum number of entries to return. The service may return fewer. If unspecified (or <= 0), at most 100 are returned. The maximum is 1000; larger values are capped to 1000.
pageToken: string, Optional. A page token from a previous ListTaskArtifacts call. The workspace is live: the agent can write between pages, so a paged listing is not a snapshot. An entry added during the walk may or may not appear, and one removed may still be listed and then fail to download.
path: string, Optional. Absolute path of the directory to list, e.g. "/workspace/userdata". Must be "/workspace" or under it, at most 1024 characters, and not contain a ".." segment. Defaults to "/workspace".
recursive: boolean, Optional. If true, descends into subdirectories. Results are breadth-first.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Response for TaskService.ListTaskArtifacts.
"artifacts": [ # The entries under the requested directory.
{ # A file or directory in a task's workspace.
"mimeType": "A String", # Output only. The detected media type. Empty for directories.
"path": "A String", # Output only. Absolute path in the task's sandbox, e.g. "/workspace/userdata/input.csv" or "/workspace/report.md". Always under "/workspace" and never contains "..". Can be passed as-is to DownloadTaskArtifact.
"sizeBytes": "A String", # Output only. Size of the file in bytes. Zero for directories.
"type": "A String", # Output only. Whether this entry is a file or a directory.
"updateTime": "A String", # Output only. Last modification time of the file as it was read: the sandbox's when read from a running sandbox, otherwise the stored object's.
},
],
"nextPageToken": "A String", # A token to retrieve the next page; empty if there are no more pages.
}
listArtifacts_next(previous_request, previous_response)
Retrieves the next page of results. Args: previous_request: The request for the previous page. (required) previous_response: The response from the request for the previous page. (required) Returns: A request object that you can call 'execute()' on to request the next page. Returns None if there are no more items in the collection.
list_next(previous_request, previous_response)
Retrieves the next page of results. Args: previous_request: The request for the previous page. (required) previous_response: The response from the request for the previous page. (required) Returns: A request object that you can call 'execute()' on to request the next page. Returns None if there are no more items in the collection.
patch(name, body=None, updateMask=None, x__xgafv=None)
Updates a task's mutable fields (e.g. schedule, priority, title). Typically allowed while the task is IDLE.
Args:
name: string, Identifier. Resource name of the task. (required)
body: object, The request body.
The object takes the form of:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
updateMask: string, Required. The list of fields to update.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
resume(name, body=None, x__xgafv=None)
Resumes a suspended task, transitioning it back to an active state (WORKING or QUEUED).
Args:
name: string, Required. The name of the task to resume. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
body: object, The request body.
The object takes the form of:
{ # Request for TaskService.ResumeTask.
"additionalBudget": { # Holistic resource caps metered across the entire task. # Optional. Additional budget to append to the task upon resumption. Used when resuming a task that was `SUSPENDED` due to reaching its budget limits. Not required (or desired) when resuming tasks suspended for other reasons (e.g., via an explicit `SuspendTask` call).
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
}
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A durable, addressable unit of work: scoped context + a goal with verifiers, assigned to an agent, and executed as a trajectory of steps. A Task is the resource users open, list, and manage. It is a light "header" (status, title, summary, outcome). The executed trajectory (steps) is not stored inline -- it is streamed live over CreateTaskBidiStream (fetched from the runtime), so a long-running/re-firing task carries no unbounded blob. Resource name (canonical): projects/{project}/locations/{location}/agents/{agent}/tasks/{task} Task is a sub-resource of Agent. A short alias projects/{project}/locations/{location}/tasks/{task} is also accepted (dual-path); the task id is unique within a project+location, so both forms resolve the same task. The short form is retained intentionally : * GetTask/ListTasks support both (dual) resource paths. * Subtasks store the short form in parent_task_id, so that reassignment of the parent task to another agent later will not require updating the subtasks, and the rendering of the task tree will not imply the agent relationships.
"assignedAgent": "A String", # Output only. The resource name of the `Agent` this task is assigned to, in the format `projects/{project}/locations/{location}/agents/{agent}`. It is derived from the create parent; any value set by the client is ignored.
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on single-task RPCs (`CreateTask`, `GetTask`, `UpdateTask`, `SuspendTask`, `ResumeTask`, `CancelTask`); not populated by `ListTasks`.
"budgetConsumptionDetail": { # Observability snapshot of budget consumption for a Task . # Output only. Current budget consumption detail of the Task.
"attributions": [ # Output only. Spend broken down by consumer.
{ # Per-consumer attribution: which unit of the Task tree incurred the spend.
"root": { # The root (owning) Task's own spend. # Output only. The root Task's own spend.
},
"spent": { # A consumer's spend, per Budget dimension. # Output only. This consumer's spend, per dimension.
"tokenCount": "A String", # Output only. Tokens spent by this consumer.
"toolCallCount": "A String", # Output only. Tool calls spent by this consumer.
},
"subTask": { # A spawned sub-Task's spend. # Output only. A spawned sub-Task's spend.
"task": "A String", # Output only. Resource name of the sub-Task that incurred the spend.
},
},
],
"tokenConsumption": { # Consumption for one budget dimension. # Output only. Token budget status. This is only populated if the Task has a token limit Budget set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
"toolCallConsumption": { # Consumption for one budget dimension. # Output only. Tool-call budget status. This is only populated if the Task has a tool call Budget limit set.
"limit": "A String", # Output only. The cap from `TaskSpec.budget` for this dimension's consumption.
"spent": "A String", # Output only. Amount consumed so far.
},
},
"createTime": "A String", # Output only. The time the task was created.
"goals": [ # Output only. Goals of the Task, including both active and completed/failed. A Task may pursue several concurrently active goals .
{ # A goal is an objective a Task works toward. A Task may pursue several concurrent goals . A goal could have one or more Verifiers as independent judges to validate the completion of it.
"displayName": "A String", # Optional. A human-readable title specifiable to the goal.
"id": "A String", # Output only. Server-assigned identifier, stable across the goal's lifetime.
"spec": "A String", # Required. The goal's objective. This is the "goal" and what the agent should pursue.
"state": "A String", # Output only. The goal's state.
"verifiers": [ # Optional. The verifier(s) that judge whether this goal is achieved. When all `required` verifiers pass, the goal will be marked `SUCCEEDED` in its `state`. If empty, the work is still checked against criteria written from the goal's `spec`, but the goal stays `ACTIVE`; add a required `auto_verification` to have it complete.
{ # A declarative success criterion for a goal. Harness-agnostic: the runtime follows the description to decide pass/fail and to repair on failure. A criterion may be checked automatically (`auto_verification`, `nl_criteria`, `command_check`) or by a human (`human_check`, resolved via a HITL elicitation at verification time). If `kind` is unset the Verifier carries no criterion and is ignored. On a Task with a local environment, verifiers do not access the environment: `nl_criteria` and `auto_verification` are judged on the record of the agent's work in the current turn, and `command_check` is not allowed.
"autoVerification": { # Judges the goal against its own `spec`, with no separate criterion to write. List it more than once to run that many independent judgements of the same objective; as with any verifier, every `required` one must pass for the goal to succeed. # Automated. Judged against the goal's own `spec`.
},
"name": "A String", # Optional. Optional label used for reporting (e.g. "tests-green").
"nlCriteria": { # An automated natural-language criterion evaluated by an autorater/agent. Wrapped in a message (rather than a bare string) so evaluation parameters (e.g. model, temperature, language) can be added without a breaking change. # Automated. A customizable natural-language rubric an autorater/agent evaluates.
"criteria": "A String", # Required. The rubric to evaluate (e.g. "Every unread high-priority thread has a summary and a draft").
},
"required": True or False, # Optional. If true, the goal cannot be marked COMPLETED unless this verifier passes. If false, the verifier is advisory (recorded, non-blocking).
"state": "A String", # Output only. The verifier's latest verdict.
},
],
},
],
"labels": { # Optional. Optional caller-supplied labels. Must follow the unified cloud labels spec (keys/values lowercase `[a-z0-9_-]`, <=63 chars). Stored as-is and returned verbatim on Get/ListTask, so the caller owns what goes in and reads back. Label names starting with `goog-` or `google-` are reserved for predefined labels. Besides user-defined billing/reporting labels, callers may stamp non-PII operational traffic annotations here under the reserved prefix (persisted on the task, so they apply to every turn and survive reconnection). Predefined: `goog-golden-query-id`: stable golden-query / CUJ id (e.g. `hello-world`); absent for organic traffic. Lets per-CUJ latency be trended independently.
"a_key": "A String",
},
"name": "A String", # Identifier. Resource name of the task.
"nextRunTime": "A String", # Output only. Next scheduled firing of a recurring template. Unset once the template is `SCHEDULE_FINISHED`, and for cron-less (event) schedules.
"parentTaskId": "A String", # Optional. If this task is a subtask, the parent task's short-form, agent-independent resource name: projects/{project}/locations/{location}/tasks/{task} The short form is used here on purpose (NOT the agent-scoped .../agents/{agent}/tasks/{task}): it stays stable when the parent is reassigned to another agent, so subtasks never need rewriting, and the task tree does not imply agent relationships .
"rootTaskId": "A String", # Output only. Lineage group key: the root of this task's tree, materialized from `parent_task_id` (a root task's own short-form name). Same short form, and for the same reason, as `parent_task_id`. One `ListTasks(filter: "root_task_id=")` returns the whole tree as a flat, paginated collection, instead of a level-by-level walk that costs one round trip per depth. The client reassembles the tree from `parent_task_id`; a page may therefore contain a task whose parent lands on a later page.
"runCount": "A String", # Output only. Runs minted so far by a recurring template, so a client can show progress against `RecurringSchedule.max_run_count`.
"scheduleState": "A String", # Output only. Scheduling lifecycle of a recurring template. Unset unless `spec.schedule.recurring` is set.
"spec": { # The centralized specification of a Task: the scoped context it runs in, when it runs, the resource guardrails, and the goal (with verifiers). # Required. The full specification of what to do, how to run it, and how to know it is done.
"budget": { # Holistic resource caps metered across the entire task. # Optional. Optional holistic budget caps metered across the entire task lifetime.
"maxToolCalls": "A String", # Optional. Maximum total tool calls across the whole task.
"maxTotalTokens": "A String", # Optional. Maximum total model tokens across the whole task.
"maxWallclock": "A String", # Optional. Maximum wall-clock duration for the task. Counts only time spent in `WORKING` or `REQUIRES_ACTION`; `IDLE`, `QUEUED`, and `SUSPENDED` do not accrue.
},
"deltaStreaming": True or False, # Optional. Whether incrementally generated content is delivered as it is produced, rather than once the step is finished. The two modes are exact duals. If false (default), every step arrives once, complete, in TaskServerEvent.step -- so a client that reads only `step` sees the whole conversation. Suited to non-chat callers that consume finished steps. If true, EVERY step instead arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an index, so a chat client sees one uniform lifecycle and never a bare `step`; reassembling a run yields the same step that would otherwise have been delivered. Content the model generates progressively -- assistant text (and the citations on it) and thoughts -- streams natively across the run's `step_delta`s as it is produced. A step that arrives whole (tool calls, tool results, elicitations, user-input echoes, errors) carries no `step_delta`: the complete step rides `step_start` and `step_stop` closes the run, since nothing is generated incrementally. The field is deliberately not named for text: what streams progressively is an implementation detail that may widen, and a client asking for incremental delivery wants it for whatever supports it. Note per-step token usage rides `step_stop`, so it is reported only when this is true.
"expectedOutput": { # Optional. Optional structured deliverable contract (reuses the Interactions ResponseFormat). When set, the agent's final output must conform to it.
"audio": { # Configuration for audio output format.
"bitRate": 42, # Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).
"delivery": "A String", # The delivery mode for the audio output.
"mimeType": "A String", # The MIME type of the audio output.
"sampleRate": 42, # Sample rate in Hz.
},
"image": { # Configuration for image output format.
"aspectRatio": "A String", # The aspect ratio for the image output.
"delivery": "A String", # The delivery mode for the image output.
"imageSize": "A String", # The size of the image output.
"mimeType": "A String", # The MIME type of the image output.
},
"structValue": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Multi-discriminator values is already enabled in GAOS
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"text": { # Configuration for text output format.
"mimeType": "A String", # The MIME type of the text output.
"schema": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # The JSON schema that the output should conform to. Only applicable when mime_type is application/json. Supports a subset of JSON Schema. `minLength`, `maxLength`, `minProperties`, `maxProperties`, `uniqueItems`, `contains`, `minContains`, and `maxContains` are ignored and not enforced; validate these in your application. `minItems` and `maxItems` are enforced. Schemas that are too complex to enforce (for example, large `maxItems` on nested arrays) return a 400 INVALID_ARGUMENT error.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
},
"video": { # Configuration for video output format.
"aspectRatio": "A String", # The aspect ratio for the video output.
"delivery": "A String", # The delivery mode for the video output.
"duration": "A String", # The duration for the video output.
"gcsUri": "A String", # The Cloud Storage URI to store the video output. Required for Vertex if delivery mode is URI.
"resolution": "A String", # The video output resolution. Defaults to 720p.
},
},
"hitlConfig": { # Session-level HITL (human-in-the-loop) configuration. Namespaces every HITL knob that a client may set at task creation, so new settings (per-tool overrides, timeout, allowed reviewers) can land without burning more top-level TaskSpec tags. `approval_mode` carries the wire default as its own `APPROVAL_MODE_UNSPECIFIED` enum value, which the server treats as `APPROVAL_MODE_ASK` (standard HITL, always prompt a human). That is also the pre-change behavior for every existing task. # Optional. Immutable. Session-level HITL (human-in-the-loop) configuration for this task. Unset means every HITL knob takes its default; see `HitlConfig` above for the individual field defaults.
"approvalMode": "A String", # Optional. Immutable. How the client wants elicitations on this task approved. Unset (or APPROVAL_MODE_UNSPECIFIED) is treated as APPROVAL_MODE_ASK.
},
"inputs": [ # Optional. The prompt expressed as Interaction steps (e.g. a ContentStep with the user's request). Reuses the Interactions step model so the same content flows into the runtime unchanged. Required for a scheduled or PRIORITY_DEFERRED task, which starts with no caller attached. Otherwise it may be empty: * Unary CreateTask with no inputs creates the task IDLE and dispatches nothing. The task starts when a caller subscribes to it on CreateTaskBidiStream (`subscribe_task`) and sends the first input. * CreateTaskBidiStream `create_task` with no inputs is a connect-only / pre-warm create; the first input is sent later as a client step. Recommended pattern for giving a task files before it runs: 1. CreateTask with empty `inputs`. The task is IDLE; nothing runs yet. 2. UploadTaskArtifact each file to `/workspace/userdata/`. 3. CreateTaskBidiStream with `subscribe_task`, then send the first input, referring to the files by their `/workspace/userdata/` paths. This dispatches the task with the uploaded files in its workspace.
{ # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
],
"maxRetries": 42, # Optional. Deprecated: tasks are not retried automatically. CreateTask and UpdateTask reject a non-zero value with INVALID_ARGUMENT.
"modelConfig": { # Selects the model the task runs on. Starts with just the model id/alias; extensible with further model parameters without a breaking change. # Optional. Optional model configuration override for the task. When set, the task runs on this model configuration for its entire lifecycle.
"effortLevel": "A String", # Optional. Reasoning/thinking depth the model runs at, case-insensitive. Gemini takes "minimal", "low", "medium" or "high", and only on models that have a thinking level; other publishers define their own set. A value the resolved model does not accept leaves its own default standing.
"maxOutputTokens": 42, # Optional. Maximum number of tokens the model may generate in each call, including any thinking tokens it spends before answering. Must not be negative; zero leaves the backend default standing. The cap also applies to the calls that summarize the task's history when its context is compacted, so a model that thinks at a high effort level may need a larger value to return a summary at all.
"model": "A String", # Optional. Publisher model resource name (an `aiplatform.googleapis.com/PublisherModel`) of the form "publishers/{publisher}/models/{model}", e.g. "publishers/anthropic/models/claude-opus-4-8" or "publishers/google/models/gemini-3-flash". The project-qualified form "projects/{project}/locations/{location}/publishers/{publisher}/models/{model}" is also accepted. When it is used, the project and location it carries take precedence over both dynamic project/location resolution and the actor config defaults. Model selection cannot be updated after task creation right now though it might be supported in the future. Empty means the actor's default gemini model.
"modelSelectionMode": "A String", # Optional. How the model in `model` was selected. Ignored when set on `LiveConfig.model_config`.
"temperature": 3.14, # Optional. Sampling temperature for the model's generation config (valid range (0.0, 2.0]); a value outside that range leaves the backend default standing.
},
"priority": "A String", # Optional. Optional priority band. Concrete tiers and quota are out of scope and deferred to a follow-up.
"schedule": { # Defines when and how a task runs. # Optional. Optional schedule controlling when/how the task runs. If unset, the task runs immediately (one-off, now).
"oneOff": { # A one-off (single) run trigger. # Run exactly once (at an absolute time or after a delay).
"delay": "A String", # Relative delay before the single run.
"runAt": "A String", # Absolute time to run at (e.g. 8 PM today).
},
"recurring": { # Defines a recurring schedule logic for repeated task executions. # Run the task spec repeatedly.
"cron": { # A recurring cron trigger. # The cron expression, e.g. "0 8 * * MON-FRI".
"expression": "A String", # Required. The cron expression, e.g. "0 8 * * MON-FRI". Any field may also be `?` or `?/step` to let the service pick the value, so that schedules do not all fire at the same moment: `?` picks one value in the field's range, and `?/step` picks a start within the first step and repeats every step from there. The pick is made once, when the schedule is created or updated, and the expression is stored with the picked values in place of `?` (e.g. "?/30 * * * *" is stored as "17-59/30 * * * *"); sending a `?` again picks new values.
"timeZone": "A String", # Optional. Optional IANA time zone name, e.g. "America/Los_Angeles". Defaults to UTC.
},
"endTime": "A String", # Optional. Do not fire after this time.
"eventSource": { # An event-driven trigger. # Identifier of a registered event source / webhook subscription whose events fire the task.
"eventSource": "A String", # Required. Identifier of a registered event source / webhook subscription whose events fire the task.
},
"maxRunCount": "A String", # Optional. Max total number of firings. Unset means unbounded.
"overlapPolicy": "A String", # Optional. What to do when a firing is due while a prior run is still active.
"startTime": "A String", # Optional. Do not fire before this time.
},
},
"scope": { # The scoped context a task runs within. # Optional. Optional scoped context: skills/tools/memory/artifacts for the task.
"allowedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Keep only these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"collaborativeProject": { # Scopes a task to a `CollaborativeProject` . Starts with the collaborative project resource reference; extensible with per-task collaborative project settings without a breaking change. # Optional. Optional collaborative project configuration for this task. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
"collaborativeProject": "A String", # Optional. The resource name of the `CollaborativeProject` this task is scoped to: `projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project}` The `{project}` segment must match the task's own Google Cloud project. Empty when the task is not scoped to a collaborative project. Only a root task (`parent_task_id` unset) may set or update this field; when `parent_task_id` is set, the subtask automatically inherits its root task's collaborative project (setting a different value is rejected with `INVALID_ARGUMENT`). Updating or clearing this field via `UpdateTask` is only allowed while the task is in the `IDLE` state (attempts in any other state are rejected with `FAILED_PRECONDITION`).
},
"dataConnectorConfig": { # Configuration for Gemini Enterprise MCP data connectors scoped to this task. # Optional. Data connector configuration for this task.
"dataConnectors": { # Optional. Map of active connector short name / data_source (e.g., "jira", "servicenow") to its full DataConnector resource name (e.g., "projects/{project}/locations/{location}/collections/{collection}/dataConnector"). If multiple connectors share a data_source, the first configured connector for that data_source is retained.
"a_key": "A String",
},
"engineResourceName": "A String", # Optional. Full resource name of the Discovery Engine Engine (e.g., "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}").
},
"environment": { # Configuration for a custom environment. # Optional. Optional server-managed sandbox environment for the task: skills and tools mounted into the sandbox plus the egress policy. Reuses the Interactions EnvironmentConfig (e.g. SKILL_REGISTRY sources to mount skills, network egress allowlist).
"env": { # Environment variables to set in the sandbox environment.
"a_key": { # An environment variable to set in the execution environment.
"credential": "A String", # Optional reference to a server-managed Credential resource by ID.
"value": "A String", # Direct string value for plain environment variables.
},
},
"environmentId": "A String", # Optional. The environment ID for the interaction. If specified, the request will update the existing environment instead of creating a new one.
"memoryMounts": [ # Optional. Memory stores mounted into the environment under `/memory/`. When merged with an agent or base environment configuration, non-conflicting mounts are preserved and request mounts take precedence on store ID or dir_name collisions.
{ # A memory store mounted into the environment under `/memory/`.
"description": "A String", # Optional. Per-mount guidance describing when the agent should read or write this memory store.
"dirName": "A String", # Optional. Directory name under `/memory//`. When omitted, defaults to the store's `memory_store_id`.
"memoryStore": "A String", # Required. Resource name or ID of the MemoryStore (e.g. `memoryStores/my-store` or `my-store`).
"mode": "A String", # Optional. Access mode granted to the environment for this store. Defaults to `READ_ONLY` when unspecified.
},
],
"networkAllowlist": { # Network egress configuration for the environment. # Allow only specific domains.
"allowlist": [ # List of allowed domains and their configurations. Set to `"disabled"` to block all network egress.
{ # A single domain allowlist rule with optional header injection.
"credential": "A String", # Optional. Reference to a server-managed Credential resource by ID.
"domain": "A String", # Domain to allow outbound requests to. Supports wildcards (e.g. '*.googleapis.com'). Use '*' to allow all domains.
"mode": "A String", # Network egress mode. Set via the `"allowlist": "disabled"` short form; must be the only rule in the allowlist and cannot be combined with `domain`, `transform` or `credential`.
"transform": { # Headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). Value: header value (e.g., "Bearer your-token").
"a_key": "A String",
},
},
],
},
"networkMode": "A String", # Network egress mode.
"sources": [
{ # A source to be mounted into the environment.
"content": "A String", # The inline content if `type` is `INLINE`.
"encoding": "A String", # Optional encoding for inline content (e.g. `base64`).
"source": "A String", # The source of the environment. For Cloud Storage, this is the Cloud Storage path. For GitHub, this is the GitHub path.
"target": "A String", # Where the source should appear in the environment.
"type": "A String",
},
],
},
"excludedTools": { # A set of tool references, each a tool's GCP resource name (`projects/.../mcpServers|endpoints/...`) with optional fine-grained method, CLI tool and resource guardrails. Wraps a repeated field so it can be used as an arm of the `ContextScope.tool_scope` oneof. LINT.IfChange(tool_refs) # Remove these tools from the agent's inherited set.
"cliToolScope": { # A CLI tool boundary restricting a subtask to designated CLI commands. # Optional. Optional CLI tool scope that the task is restricted to. Unset means all CLI tools are allowed. Set with an empty `cli_tools` list means all CLI tools are denied.
"cliTools": [ # Optional. Allowed CLI tools for the task. Example: ["gmail send_message", "calendar list_events"].
"A String",
],
},
"methods": [ # Optional. Optional fine-grained method selectors for the referenced tools. Format: "/methods/".
"A String",
],
"resources": [ # Optional. Optional resource identifiers that the task is restricted to interact with.
{ # A specific resource boundary restricting an agent's access to designated entities.
"recipients": [ # Optional. Optional recipients email boundaries for communication tools. Example: ["alice@gmail.com", "bob@google.com"].
"A String",
],
"resource": "A String", # Optional. The specific resource identifier (e.g. thread_id, doc_id, repo name). Examples: * GMAIL_THREAD: "18df123456789abc" * GOOGLE_CHAT_THREAD: "spaces/AAA/threads/BBB" * GITHUB_REPOSITORY: "GoogleCloudPlatform/kubectl"
"resourceType": "A String", # Required. The type of resource being scoped.
"selfCreated": True or False, # Optional. For cold outreach / outbound threads when resource_id doesn't exist. Grants access ONLY to resources created by this task instance.
},
],
"toolNames": [ # Optional. Tool GCP resource names. For example: * MCP server: `projects/my-project/locations/us-central1/mcpServers/jira` * Endpoint: `projects/my-project/locations/us-central1/endpoints/drive`
"A String",
],
},
"externalBrowser": { # A browser on the connecting client (e.g. the user's own, signed-in Chrome) that a task's browser actions run on. The actions are relayed to the client, so the client must stay connected while they happen. The task's other operations (files, commands) still run where `environment_config` puts them. # Optional. Optional browser on the connecting client that the task's browser actions run on, instead of a browser in a server-managed sandbox. Supported with `environment`, `no_environment`, or no `environment_config`.
},
"externalMount": { # A directory on the connecting client (e.g. the user's local machine) mounted into a task's server-managed environment. # Optional. Optional directory on the connecting client mounted into the task's server-managed environment. File operations under its `mount_path` are relayed to the client. Supported only when `environment` is set.
"mountPath": "A String", # Optional. Absolute path in the environment where the directory is mounted. Empty means `/workspace/desktop`. When set, must be `/workspace/{name}`, where `{name}` is 1-63 lowercase letters, digits, `_` or `-`, starts with a letter or digit, and is not one of the names other mounts own under `/workspace`: `skills`, `core`, `memory`, `inputs`, `artifacts`, `deliverables` or `userdata`.
"sourcePath": "A String", # Optional. Absolute path of the folder on the connecting client (the mount source). Interpreted only by the client; the server never resolves it.
},
"localEnvironment": { # Configuration for an environment that lives on the client connection rather than in a server-managed sandbox. When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed `EnvironmentConfig` (remote_environment), since the environment is either on the client or in a server sandbox, never both. This governs only the agent's built-in environment. Client-declared function tools are always executed on the client regardless of this field. # Optional. Optional client-side ("local") environment: the agent's built-in filesystem/shell operations are yielded to the connecting client (e.g. the gogo desktop client) to execute locally, instead of running in a server-managed sandbox. Mirrors Interaction.local_environment and is mutually exclusive with `environment`. (Independent of any client-declared function tools, which are always executed on the client regardless of this field.)
},
"memoryConfig": { # Task-level memory settings: which sources memory draws from, and whether memory is active for this task at all. # Optional. Memory settings for this task.
"disableMemory": True or False, # Optional. If true, the agent neither reads existing memories into the prompt nor forms new ones from this task. Memory is on by default, and this can only turn it off, never back on: * Agent memory enabled, this true: off for this task. * Agent memory enabled, this false or unset: on. * Agent memory disabled: off, whatever this says. Because a task belongs to a single end user's interaction, a surface that knows the user can use this to turn memory off for one user of a shared agent; memory keeps working for the agent's other users. `Agent.memory_config.disable_memory` wins because it is the mutable one. It can be turned on after tasks have already been created, and a stored task spec keeps whatever it was created with — so if a spec could re-enable memory, the agent-level switch would be unable to cover the tasks that already exist. The two are therefore OR'ed, and the agent's current value is re-applied every time a session opens, including on a resume. Scoped to this task. Memories already stored for the agent are retained and stay readable by the agent's users; this governs only whether this task can access and modify them.
"knowledgeCatalogConfig": { # Configuration for enterprise Knowledge Catalog metadata discovery. # Optional. Configuration for enterprise Knowledge Catalog search.
"enabledConnectors": [ # Optional. Filter list of system/connector technology names (e.g., "bigquery", "looker", "spanner"). If empty, all indexed catalog connectors are searched.
"A String",
],
"knowledgeCatalogEnabled": True or False, # Optional. If true, enables searching enterprise metadata in Google Cloud Knowledge Catalog.
"projectId": "A String", # Optional. GCP project ID to scope Knowledge Catalog searches.
},
},
},
"subtaskConfig": { # Configuration and limits for subtasks spawned by this task. # Optional. Configuration and limits for subtasks spawned by this task.
"maxDepth": 42, # Optional. The maximum depth of subtask hierarchy allowed under this task. Must be between 0 and 5, inclusive. When unset on a root task, defaults to 5. For a subtask, it is clamped to at most parent.max_depth - 1 (defaulting to parent.max_depth - 1 if unspecified). A value of 0 means this task cannot spawn any subtasks.
},
"systemInstruction": "A String", # Optional. Optional standing instruction applied across the whole task.
},
"status": "A String", # Output only. The coarse, durable status of the task.
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Output only. Explanation for the current state, when the state alone is not enough to act on (today: `SUSPENDED`). Cleared when the task leaves that state.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"statusUpdateTime": "A String", # Output only. The time the task's status was last updated.
"summary": "A String", # Output only. A rolling, system-generated summary of the task's progress/result.
"title": "A String", # Optional. Optional human-readable title for listing surfaces.
"updateTime": "A String", # Output only. The time the task was last updated.
}
stream(name, continuationToken=None, nextStepSeqNum=None, snapshot=None, x__xgafv=None)
Read-only server-stream of a task's execution by id: trajectory steps and status changes, resumable from a step sequence number. Unlike CreateTaskBidiStream, it does not accept client inputs -- use it to observe or replay a task (the trajectory is not stored on the Task resource). This is the entry point for *observers*: it tails the trajectory from interaction storage without restoring the runtime actor, so it adds no restore latency and continues to follow output that a participant driving the task on a CreateTaskBidiStream connection produces. Observe-only clients should prefer this over a subscribe_task connect on CreateTaskBidiStream, which restores the actor and is meant for clients that will send input.
Args:
name: string, Required. The name of the task to stream. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
continuationToken: string, Optional. Opaque resume cursor, as issued on TaskServerEvent.continuation_token. Replay continues immediately after the event that carried the token. Takes precedence over next_step_seq_num when both are set. A token this stream cannot redeem is rejected with INVALID_ARGUMENT rather than silently falling back to the numeric cursor, so a client cannot mistake a rejected resume for a replay from the start; reconnect without a token instead. That covers a malformed token, one issued by a connection whose delta streaming differs from this one's (see TaskSpec.delta_streaming), one issued while the server derived task status differently, and any token on a recurring task. A token names a position in the task it was issued on; send it only to that task. It carries no task id, so a token from another task is not rejected, and what it returns is undefined. A token whose position is past the events stored so far is not an error either, because storage can trail the live stream that issued the token: the replay skips everything up to that position, so a snapshot may return no events.
nextStepSeqNum: string, Optional. The next step sequence number to resume from. When zero, streams from the beginning of the available trajectory.
snapshot: boolean, Optional. If true, streams only the events produced up to the current point in time and terminates the stream once all existing events are sent, rather than tailing and waiting for future events.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Server -> Client message for TaskService.CreateTaskBidiStream. * The first message carries a connect_reply (task_created or task_subscribed). * The steady-state pattern is repeated `events` (steps, status). * The last message carries an end_signal.
"ackInputSeqNum": "A String", # Optional. When non-zero, confirms cumulative receipt of client input through this seq_num (inclusive).
"assignedAgentIdentity": "A String", # Output only. The resolved Agent Identity (SPIFFE ID) of the `Agent` this task is assigned to. Populated on the first message of the stream.
"events": [ # Steady-state events from the server (trajectory steps -- including elicitation/tool-call HITL requests -- and status changes).
{ # A single Server -> Client event. There is intentionally no non-terminal error/notice branch. Transient, retriable failures (tool-fetch retry, rate-limit, scheduler retry) are handled by runtime retry (bounded by TaskSpec.max_retries) and, if surfaced at all, appear as trajectory steps; the terminal error is reported once via TaskCompletedEvent.outcome.status (google.rpc.Status). This follows the Interactions events.proto, which deprecated its dedicated non-terminal InteractionPausedEvent and reports terminal status on InteractionCompletedEvent.
"continuationToken": "A String", # Optional. Opaque resume cursor covering everything delivered through this event, inclusive. A client that keeps the token from the last event it processed and passes it back on SubscribeTaskEvent.continuation_token or StreamTaskRequest.continuation_token resumes at the next event, with no gap and no duplicate. Opaque: the encoding is a server implementation detail and may change without notice. Do not parse it, compare two of them, or derive ordering from it -- order by `seq_num`. Carries no task id, because every RPC that redeems a token already names the task it applies to. It is a position, not a capability: it grants no access on its own, and the task's IAM check is what authorizes the read. This is the resume cursor. Resuming by number (next_step_seq_num on SubscribeTaskEvent and StreamTaskRequest) is slated for deprecation: a number cannot address a position inside a streamed step, while the token can, so a reconnect mid-answer does not re-send the part of that answer the client already rendered. `seq_num` remains for ordering only.
"eventId": "A String", # Optional. The TaskClientEvent.event_id this event was derived from, echoed back verbatim. Set only on the events that carry a client input back out: the `step` echoing the input, and the `step_start` of a streamed step the input opened. Empty everywhere else -- on model-generated steps the server produced on its own, on the step_delta/step_stop frames continuing a run (correlate those by `index` with their step_start), and on any event whose client input carried no event_id. Purely a correlation handle: it does not order or acknowledge anything, and the server never derives behavior from it. Since the server does not enforce uniqueness, a client that reuses an id sees it on every echo it produced. Delivered to every client subscribed to the task, not just the one that sent the input, including on a later replay from storage.
"seqNum": "A String", # Required. 1-based, non-decreasing sequence number within the server direction, stable across reconnects, so it can be used to resume: a given event carries the same number however the stream is (re)connected. Gapless on a stream delivered from the beginning. Clients acknowledge receipt via ack_output_seq_num and resume via SubscribeTaskEvent.next_step_seq_num. A resume with next_step_seq_num = 0 (or unset) restarts from the first still available step. A number identifies a resume point, not an event, so it is not unique: consecutive events can share one. An event derived from another (an artifacts_changed delta carrying the plan its step just wrote) repeats its source's number rather than taking the next, which keeps the numbering a function of the stream alone and guarantees a cursor never lands between the two. Acknowledging a number acknowledges every event carrying it. A resume can begin AFTER the requested number. next_step_seq_num counts events, but a streamed step spans several of them, so a cursor can point inside a run; the server then suppresses that run's remaining step_delta/step_stop rather than deliver frames for a step the client never saw opened, and resumes at the next step boundary. Numbering is unchanged by that suppression -- keeping it stable is what makes a cursor meaningful across connections -- so the first delivered event may be a later number than asked for. Treat the sequence as monotonic, not densely contiguous, when resuming.
"statusChanged": { # Signals a task status transition. # A coarse status transition (e.g. WORKING -> REQUIRES_ACTION when the task is waiting on a human response).
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Machine-readable reason and details for why the task entered this status (e.g. `SUSPENDED`).
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
"taskStatus": "A String", # The new coarse task status.
},
"step": { # A step in the interaction. # A trajectory output step (thought, tool call, content, elicitation_call, etc.). Human-in-the-loop requests are just steps: the server emits an ElicitationCallStep (for an approval / choice) or a ToolCallStep (for a client-executed tool), and the client responds with the matching ElicitationResultStep / ToolResultStep, correlated by elicitation_id / call_id. The kind of action required is inferred from the step's type, so there is no separate "action required" event.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
"stepDelta": { # One chunk of a streamed step, carrying only the content generated since the previous chunk. Chunks sharing an `index` belong to one step and concatenate in the order received.
"delta": {
"argumentsDelta": {
"arguments": "A String",
},
"audio": {
"channels": 42, # The number of audio channels.
"data": "A String",
"mimeType": "A String",
"rate": 42, # Deprecated. Use sample_rate instead. The value is ignored.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String",
},
"document": {
"data": "A String",
"mimeType": "A String",
"uri": "A String",
},
"functionResult": {
"isError": True or False,
"name": "A String",
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"image": {
"data": "A String",
"mimeType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String",
},
"serverToolCall": {
"codeExecutionCall": {
"arguments": { # The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": {
},
"googleMapsCall": {
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": {
"arguments": { # The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
},
"mcpServerToolCall": {
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String",
"serverName": "A String",
},
"processingCall": { # Streaming delta for a server-initiated media processing step.
},
"retrievalCall": { # Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the Retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": {
"arguments": { # The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"serverToolResult": {
"codeExecutionResult": {
"isError": True or False,
"result": "A String",
},
"fileSearchResult": {
"result": [
{ # The result of the File Search.
},
],
},
"googleMapsResult": {
"result": [ # The results of the Google Maps.
{ # The result of the Google Maps.
"places": [ # The places that were found.
{
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
],
"widgetContextToken": "A String", # Resource name of the Google Maps widget context token.
},
],
},
"googleSearchResult": {
"isError": True or False,
"result": [
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": {
"name": "A String",
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String",
},
"processingResult": { # Streaming delta for the result of a server-initiated media processing step.
},
"retrievalResult": { # Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": {
"isError": True or False,
"result": [
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"text": {
"text": "A String",
},
"textAnnotationDelta": {
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
},
"thoughtSignature": {
"signature": "A String", # Signature to match the backend source to be part of the generation.
},
"thoughtSummary": {
"content": { # The content of the response. # A new summary item to be added to the thought.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
},
"video": {
"data": "A String",
"mimeType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String",
},
},
"index": 42,
},
"stepStart": { # Opens a streamed step. Emitted only under `TaskSpec.delta_streaming`, which documents the two delivery modes in full. Under `delta_streaming` EVERY step arrives as a `step_start` / `step_delta`* / `step_stop` run sharing an `index`, and a bare `step` is never emitted. Reassembling a run yields the same Step that `step` above would otherwise have delivered. What follows a `step_start` depends on whether the content is generated progressively. Assistant text (and the citations on it) and thoughts stream across the run's `step_delta`s as they are produced, so for those this field carries the step's shape (role, type) with its generated content left empty. A step that arrives whole -- tool calls, tool results, elicitations, user-input echoes, errors -- carries no `step_delta` at all: the COMPLETE step rides this field, and `step_stop` closes the run.
"index": 42,
"step": { # A step in the interaction.
"modelOutput": { # Output generated by the model.
"content": [
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
},
"thought": { # A thought step.
"signature": "A String", # A signature hash for backend validation.
"summary": [ # A summary of the thought.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"toolCall": { # Tool call step.
"codeExecutionCall": { # Code execution call step.
"arguments": { # The arguments to pass to the code execution. # Required. The arguments to pass to the code execution.
"code": "A String", # The code to be executed.
"language": "A String", # Programming language of the `code`.
},
},
"fileSearchCall": { # File Search call step.
},
"functionCall": { # A function tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The arguments to pass to the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool to call.
},
"googleMapsCall": { # Google Maps call step.
"arguments": { # The arguments to pass to the Google Maps tool. # The arguments to pass to the Google Maps tool.
"queries": [ # The queries to be executed.
"A String",
],
},
},
"googleSearchCall": { # Google Search call step.
"arguments": { # The arguments to pass to Google Search. # Required. The arguments to pass to Google Search.
"queries": [ # Web search queries for the following-up web search.
"A String",
],
},
"searchType": "A String", # The type of search grounding enabled.
},
"id": "A String", # Required. A unique ID for this specific tool call.
"mcpServerToolCall": { # MCPServer tool call step.
"arguments": { # `Struct` represents a structured data value, consisting of fields which map to dynamically typed values. # Required. The JSON object of arguments for the function.
"fields": [ # Dynamically typed fields. List instead of map because LLMs are sensitive to ordering, and we want to give users full control.
{ # Represents a single field in a struct.
"name": "A String",
"value": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
],
},
"name": "A String", # Required. The name of the tool which was called.
"serverName": "A String", # Required. The name of the used MCP server.
},
"processingCall": { # A server-initiated processing step for media analysis (e.g. video understanding).
},
"retrievalCall": { # Retrieval call step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc. RetrievalType decides which tool is used.
"arguments": { # The arguments to pass to Retrieval tools. # Required. The arguments to pass to the retrieval tool.
"queries": [ # Queries for Retrieval information.
"A String",
],
},
"retrievalType": "A String", # The type of retrieval tools.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextCall": { # URL context call step.
"arguments": { # The arguments to pass to the URL context. # Required. The arguments to pass to the URL context.
"urls": [ # The URLs to fetch.
"A String",
],
},
},
},
"toolResult": { # Tool result step.
"callId": "A String", # Required. ID to match the ID from the function call block.
"codeExecutionResult": { # Code execution result step.
"isError": True or False, # Whether the code execution resulted in an error.
"result": "A String", # Required. The output of the code execution.
},
"fileSearchResult": { # File Search result step.
},
"functionResult": { # Result of a function tool call.
"isError": True or False, # Whether the tool call resulted in an error.
"name": "A String", # The name of the tool that was called.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The result of the tool call.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
},
"googleMapsResult": { # Google Maps result step.
"result": [
{ # The result of the Google Maps.
"places": [
{
"name": "A String",
"placeId": "A String",
"reviewSnippets": [
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String",
},
],
"widgetContextToken": "A String",
},
],
},
"googleSearchResult": { # Google Search result step.
"isError": True or False, # Whether the Google Search resulted in an error.
"result": [ # Required. The results of the Google Search.
{ # The result of the Google Search.
"searchSuggestions": "A String", # Web content snippet that can be embedded in a web page or an app webview.
},
],
},
"mcpServerToolResult": { # MCPServer tool result step.
"name": "A String", # Name of the tool which is called for this specific tool call.
"result": { # `Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. # Required. The output from the MCP server call. Can be simple text or rich content.
"boolValue": True or False, # Represents a boolean value.
"contentValue": { # The content of the response. # Represents rich content (text, image, etc.).
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
"listValue": { # `ListValue` is a wrapper around a repeated field of values. # Represents a repeated `Value`.
"values": [ # Repeated field of dynamically typed values.
# Object with schema name: GenaiValue
],
},
"nullValue": "A String", # Represents a null value.
"numberValue": 3.14, # Represents a double value.
"stringValue": "A String", # Represents a string value.
"structValue": # Object with schema name: GenaiStruct # Represents a structured value.
},
"serverName": "A String", # The name of the used MCP server.
},
"processingResult": { # The result of a server-initiated media processing step.
},
"retrievalResult": { # Vertex Retrieval result step. Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search, etc.
"isError": True or False, # Whether the retrieval resulted in an error.
},
"signature": "A String", # A signature hash for backend validation.
"urlContextResult": { # URL context result step.
"isError": True or False, # Whether the URL context resulted in an error.
"result": [ # Required. The results of the URL context.
{ # The result of the URL context.
"status": "A String", # The status of the URL retrieval.
"url": "A String", # The URL that was fetched.
},
],
},
},
"userInput": { # Input provided by the user. # DO NOT USE -- These are for 3P JSON only
"contentList": { # A list of Content. # The content of the step. An array of Content objects.
"contents": [ # The contents of the list.
{ # The content of the response.
"audio": { # An audio content block.
"channels": 42, # The number of audio channels.
"data": "A String", # The audio content.
"mimeTypeString": "A String", # Flexible MIME type string of the audio, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"sampleRate": 42, # The sample rate of the audio.
"uri": "A String", # The URI of the audio.
},
"document": { # A document content block.
"data": "A String", # The document content.
"mimeTypeString": "A String", # Flexible MIME type string of the document, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"uri": "A String", # The URI of the document.
},
"image": { # An image content block.
"data": "A String", # The image content.
"mimeTypeString": "A String", # Flexible MIME type string of the image, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the image.
},
"text": { # A text content block.
"annotations": [ # Citation information for model-generated content.
{ # Citation information for model-generated content.
"endIndex": 42, # End of the attributed segment, exclusive.
"fileCitation": { # A file citation annotation. # A file citation annotation.
"customMetadata": { # User provided metadata about the retrieved context.
"a_key": "", # Properties of the object.
},
"documentUri": "A String", # The URI of the file.
"fileName": "A String", # The name of the file.
"mediaId": "A String", # Media ID in-case of image citations, if applicable.
"pageNumber": 42, # Page number of the cited document, if applicable.
"source": "A String", # Source attributed for a portion of the text.
},
"placeCitation": { # A place citation annotation. # A place citation annotation.
"name": "A String", # Title of the place.
"placeId": "A String", # The ID of the place, in `places/{place_id}` format.
"reviewSnippets": [ # Snippets of reviews that are used to generate answers about the features of a given place in Google Maps.
{ # Encapsulates a snippet of a user review that answers a question about the features of a specific place in Google Maps.
"reviewId": "A String", # The ID of the review snippet.
"title": "A String", # Title of the review.
"url": "A String", # A link that corresponds to the user review on Google Maps.
},
],
"url": "A String", # URI reference of the place.
},
"speechMetadata": { # Speech annotation for text content. # Speech annotation for text content.
"speaker": "A String", # The speaker to associate with this turn.
"style": "A String", # Style instruction for the speech synthesis.
},
"startIndex": 42, # Start of segment of the response that is attributed to this source. Index indicates the start of the segment, measured in bytes.
"urlCitation": { # A URL citation annotation. # NOTE: We use these instead of the Citation message for historical reasons. A URL citation annotation.
"title": "A String", # The title of the URL.
"url": "A String", # The URL.
},
"wordInfo": { # Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution. # Word-level ASR annotation with timing and speaker info.
"endOffset": "A String", # End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"speaker": "A String", # Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
"startOffset": "A String", # Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
"text": "A String", # The transcribed word.
},
},
],
"text": "A String", # Required. The text content.
},
"video": { # A video content block.
"data": "A String", # The video content.
"mimeTypeString": "A String", # Flexible MIME type string of the video, superseding mime_type = 1. Note: Bespoke logic in the GAOS parser/serializer maps this to the "mime_type" JSON key.
"name": "A String", # A user-defined name for this content block. Can be referenced by the model in the final response.
"processingConfig": {
"static": {
"endOffset": "A String", # Optional. Segment end time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "30s". Must be non-negative and greater than `start_offset` if `start_offset` is set.
"fps": 3.14, # Optional. Video frame-rate sampling density.
"startOffset": "A String", # Optional. Segment start time. Specified as a decimal number of seconds followed by an 's' suffix, e.g., "10.5s". Must be non-negative.
},
},
"processingType": "A String",
"resolution": "A String", # The resolution of the media.
"uri": "A String", # The URI of the video.
},
},
],
},
"contentString": "A String", # The content of the step. A single string.
},
},
},
"stepStop": { # Closes a streamed step, carrying its token usage. No further `step_delta` arrives for this `index`.
"index": 42,
"stepUsage": { # Statistics on the interaction request's token usage. # Model usage stats for this specific step.
"billableUsage": { # Accumulated billable token usage across all continuation calls. # Accumulated billable token usage across all continuation calls.
"totalCachedTokens": 42, # Total billable cached tokens across all continuation calls.
"totalInputTokens": 42, # Total billable input tokens across all continuation calls.
"totalOutputTokens": 42, # Total billable output tokens across all continuation calls.
"totalThoughtTokens": 42, # Total billable thought tokens across all continuation calls.
"totalTokens": 42, # Total billable token count across all continuation calls.
},
"cachedTokensByModality": [ # A breakdown of cached token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"compactionUsageMetadata": { # Token usage metadata for context compaction. # Token usage metadata for context compaction.
"inputTokenCount": 42, # Number of tokens processed in the compaction input.
"outputTokenCount": 42, # Number of tokens generated in the compaction output.
"postcompactionTokenCount": "A String", # Estimated total token count of the conversation context after compaction.
"precompactionStepCount": 42, # Number of conversation steps (user turns) before compaction.
"precompactionTokenCount": "A String", # Estimated total token count of the conversation context before compaction.
},
"groundingToolCount": [ # Grounding tool count.
{ # The number of grounding tool counts.
"count": 42, # The number of grounding tool counts.
"searchQueryCount": 42, # Number of unique search queries generated by the model for this tool.
"type": "A String", # The grounding tool type associated with the count.
},
],
"initialInputTokens": 42, # Number of input tokens used in the first turn of this interaction.
"inputTokensByModality": [ # A breakdown of input token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"modelInvocationTokenCounts": [ # Per-invocation token count breakdown. For simple requests, this contains a single entry. For requests with server-side tool use, this contains one entry per model invocation, ordered chronologically. This is the source of truth for billing.
{ # Token count breakdown for a single model invocation (main model only) within a request. For simple requests without tool use, there is a single invocation. For requests with server-side tool use, there is one invocation per tool-use iteration.
"cacheTokensDetails": [ # Per-modality breakdown of cached tokens within this invocation's prompt. Cached tokens are discounted for billing (priced at the cache rate, not the full input rate). This is a subset of prompt_tokens_details.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"candidatesTokensDetails": [ # Per-modality breakdown of response tokens for this invocation. Includes the model's text output, function calls, or final answer. Does not include thought tokens.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"promptTokensDetails": [ # Per-modality breakdown of prompt tokens for this invocation. Includes all tokens sent to the model: user content, system instructions, formatting/control tokens, tool declarations, and any previous-turn context accumulated during tool use.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"thoughtsTokensDetails": [ # Per-modality breakdown of thought tokens for this invocation (for thinking models). Includes auxiliary control tokens produced by the model that delimit thought blocks.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
},
],
"nonGroundingModelInvocationTokenCounts": [ # Per-invocation token count breakdown for non-grounding invocations (grounding prompt/cache tokens excluded).
{ # Token count breakdown for a single model invocation (main model only) within a request. For simple requests without tool use, there is a single invocation. For requests with server-side tool use, there is one invocation per tool-use iteration.
"cacheTokensDetails": [ # Per-modality breakdown of cached tokens within this invocation's prompt. Cached tokens are discounted for billing (priced at the cache rate, not the full input rate). This is a subset of prompt_tokens_details.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"candidatesTokensDetails": [ # Per-modality breakdown of response tokens for this invocation. Includes the model's text output, function calls, or final answer. Does not include thought tokens.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"promptTokensDetails": [ # Per-modality breakdown of prompt tokens for this invocation. Includes all tokens sent to the model: user content, system instructions, formatting/control tokens, tool declarations, and any previous-turn context accumulated during tool use.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"thoughtsTokensDetails": [ # Per-modality breakdown of thought tokens for this invocation (for thinking models). Includes auxiliary control tokens produced by the model that delimit thought blocks.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
},
],
"outputTokensByModality": [ # A breakdown of output token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"rawPromptToken": 42, # Output only.
"toolCallUsage": [ # Output only. Per-tool call statistics, sorted by (`tool_type`, `name`).
{ # Usage statistics for one tool, aggregated over the interaction.
"name": "A String", # The function name as declared in the request. Set only when `tool_type` is TOOL_TYPE_FUNCTION; empty for all other tool types.
"serverExecutedCount": 42, # Of `tool_call_count`, calls dispatched to and run by the server, whether or not they succeeded.
"toolCallCount": 42, # Number of calls to this tool that the model generated.
"toolType": "A String",
},
],
"toolUseTokensByModality": [ # A breakdown of tool-use token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"totalCachedTokens": 42, # Number of tokens in the cached part of the prompt (the cached content).
"totalInputTokens": 42, # Number of tokens in the prompt (context).
"totalModelInvocations": 42, # Total number of LLM model invocations executed during the interaction turn (including retries and multi-step tool loop calls).
"totalOutputTokens": 42, # Total number of tokens across all the generated responses.
"totalThoughtTokens": 42, # Number of tokens of thoughts for thinking models.
"totalTokens": 42, # Total token count for the interaction request (prompt + responses + other internal tokens).
"totalToolUseTokens": 42, # Number of tokens present in tool-use prompt(s).
},
"usage": { # Statistics on the interaction request's token usage. # Cumulative model usage stats from the start of the session.
"billableUsage": { # Accumulated billable token usage across all continuation calls. # Accumulated billable token usage across all continuation calls.
"totalCachedTokens": 42, # Total billable cached tokens across all continuation calls.
"totalInputTokens": 42, # Total billable input tokens across all continuation calls.
"totalOutputTokens": 42, # Total billable output tokens across all continuation calls.
"totalThoughtTokens": 42, # Total billable thought tokens across all continuation calls.
"totalTokens": 42, # Total billable token count across all continuation calls.
},
"cachedTokensByModality": [ # A breakdown of cached token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"compactionUsageMetadata": { # Token usage metadata for context compaction. # Token usage metadata for context compaction.
"inputTokenCount": 42, # Number of tokens processed in the compaction input.
"outputTokenCount": 42, # Number of tokens generated in the compaction output.
"postcompactionTokenCount": "A String", # Estimated total token count of the conversation context after compaction.
"precompactionStepCount": 42, # Number of conversation steps (user turns) before compaction.
"precompactionTokenCount": "A String", # Estimated total token count of the conversation context before compaction.
},
"groundingToolCount": [ # Grounding tool count.
{ # The number of grounding tool counts.
"count": 42, # The number of grounding tool counts.
"searchQueryCount": 42, # Number of unique search queries generated by the model for this tool.
"type": "A String", # The grounding tool type associated with the count.
},
],
"initialInputTokens": 42, # Number of input tokens used in the first turn of this interaction.
"inputTokensByModality": [ # A breakdown of input token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"modelInvocationTokenCounts": [ # Per-invocation token count breakdown. For simple requests, this contains a single entry. For requests with server-side tool use, this contains one entry per model invocation, ordered chronologically. This is the source of truth for billing.
{ # Token count breakdown for a single model invocation (main model only) within a request. For simple requests without tool use, there is a single invocation. For requests with server-side tool use, there is one invocation per tool-use iteration.
"cacheTokensDetails": [ # Per-modality breakdown of cached tokens within this invocation's prompt. Cached tokens are discounted for billing (priced at the cache rate, not the full input rate). This is a subset of prompt_tokens_details.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"candidatesTokensDetails": [ # Per-modality breakdown of response tokens for this invocation. Includes the model's text output, function calls, or final answer. Does not include thought tokens.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"promptTokensDetails": [ # Per-modality breakdown of prompt tokens for this invocation. Includes all tokens sent to the model: user content, system instructions, formatting/control tokens, tool declarations, and any previous-turn context accumulated during tool use.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"thoughtsTokensDetails": [ # Per-modality breakdown of thought tokens for this invocation (for thinking models). Includes auxiliary control tokens produced by the model that delimit thought blocks.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
},
],
"nonGroundingModelInvocationTokenCounts": [ # Per-invocation token count breakdown for non-grounding invocations (grounding prompt/cache tokens excluded).
{ # Token count breakdown for a single model invocation (main model only) within a request. For simple requests without tool use, there is a single invocation. For requests with server-side tool use, there is one invocation per tool-use iteration.
"cacheTokensDetails": [ # Per-modality breakdown of cached tokens within this invocation's prompt. Cached tokens are discounted for billing (priced at the cache rate, not the full input rate). This is a subset of prompt_tokens_details.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"candidatesTokensDetails": [ # Per-modality breakdown of response tokens for this invocation. Includes the model's text output, function calls, or final answer. Does not include thought tokens.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"promptTokensDetails": [ # Per-modality breakdown of prompt tokens for this invocation. Includes all tokens sent to the model: user content, system instructions, formatting/control tokens, tool declarations, and any previous-turn context accumulated during tool use.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"thoughtsTokensDetails": [ # Per-modality breakdown of thought tokens for this invocation (for thinking models). Includes auxiliary control tokens produced by the model that delimit thought blocks.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
},
],
"outputTokensByModality": [ # A breakdown of output token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"rawPromptToken": 42, # Output only.
"toolCallUsage": [ # Output only. Per-tool call statistics, sorted by (`tool_type`, `name`).
{ # Usage statistics for one tool, aggregated over the interaction.
"name": "A String", # The function name as declared in the request. Set only when `tool_type` is TOOL_TYPE_FUNCTION; empty for all other tool types.
"serverExecutedCount": 42, # Of `tool_call_count`, calls dispatched to and run by the server, whether or not they succeeded.
"toolCallCount": 42, # Number of calls to this tool that the model generated.
"toolType": "A String",
},
],
"toolUseTokensByModality": [ # A breakdown of tool-use token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"totalCachedTokens": 42, # Number of tokens in the cached part of the prompt (the cached content).
"totalInputTokens": 42, # Number of tokens in the prompt (context).
"totalModelInvocations": 42, # Total number of LLM model invocations executed during the interaction turn (including retries and multi-step tool loop calls).
"totalOutputTokens": 42, # Total number of tokens across all the generated responses.
"totalThoughtTokens": 42, # Number of tokens of thoughts for thinking models.
"totalTokens": 42, # Total token count for the interaction request (prompt + responses + other internal tokens).
"totalToolUseTokens": 42, # Number of tokens present in tool-use prompt(s).
},
},
"stepUsage": { # Statistics on the interaction request's token usage. # Optional. Token usage for one model call. Populated on at most one event per model call regardless of `TaskSpec.delta_streaming`, and absent on non-model events (tool results, user-input echoes, status changes).
"billableUsage": { # Accumulated billable token usage across all continuation calls. # Accumulated billable token usage across all continuation calls.
"totalCachedTokens": 42, # Total billable cached tokens across all continuation calls.
"totalInputTokens": 42, # Total billable input tokens across all continuation calls.
"totalOutputTokens": 42, # Total billable output tokens across all continuation calls.
"totalThoughtTokens": 42, # Total billable thought tokens across all continuation calls.
"totalTokens": 42, # Total billable token count across all continuation calls.
},
"cachedTokensByModality": [ # A breakdown of cached token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"compactionUsageMetadata": { # Token usage metadata for context compaction. # Token usage metadata for context compaction.
"inputTokenCount": 42, # Number of tokens processed in the compaction input.
"outputTokenCount": 42, # Number of tokens generated in the compaction output.
"postcompactionTokenCount": "A String", # Estimated total token count of the conversation context after compaction.
"precompactionStepCount": 42, # Number of conversation steps (user turns) before compaction.
"precompactionTokenCount": "A String", # Estimated total token count of the conversation context before compaction.
},
"groundingToolCount": [ # Grounding tool count.
{ # The number of grounding tool counts.
"count": 42, # The number of grounding tool counts.
"searchQueryCount": 42, # Number of unique search queries generated by the model for this tool.
"type": "A String", # The grounding tool type associated with the count.
},
],
"initialInputTokens": 42, # Number of input tokens used in the first turn of this interaction.
"inputTokensByModality": [ # A breakdown of input token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"modelInvocationTokenCounts": [ # Per-invocation token count breakdown. For simple requests, this contains a single entry. For requests with server-side tool use, this contains one entry per model invocation, ordered chronologically. This is the source of truth for billing.
{ # Token count breakdown for a single model invocation (main model only) within a request. For simple requests without tool use, there is a single invocation. For requests with server-side tool use, there is one invocation per tool-use iteration.
"cacheTokensDetails": [ # Per-modality breakdown of cached tokens within this invocation's prompt. Cached tokens are discounted for billing (priced at the cache rate, not the full input rate). This is a subset of prompt_tokens_details.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"candidatesTokensDetails": [ # Per-modality breakdown of response tokens for this invocation. Includes the model's text output, function calls, or final answer. Does not include thought tokens.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"promptTokensDetails": [ # Per-modality breakdown of prompt tokens for this invocation. Includes all tokens sent to the model: user content, system instructions, formatting/control tokens, tool declarations, and any previous-turn context accumulated during tool use.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"thoughtsTokensDetails": [ # Per-modality breakdown of thought tokens for this invocation (for thinking models). Includes auxiliary control tokens produced by the model that delimit thought blocks.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
},
],
"nonGroundingModelInvocationTokenCounts": [ # Per-invocation token count breakdown for non-grounding invocations (grounding prompt/cache tokens excluded).
{ # Token count breakdown for a single model invocation (main model only) within a request. For simple requests without tool use, there is a single invocation. For requests with server-side tool use, there is one invocation per tool-use iteration.
"cacheTokensDetails": [ # Per-modality breakdown of cached tokens within this invocation's prompt. Cached tokens are discounted for billing (priced at the cache rate, not the full input rate). This is a subset of prompt_tokens_details.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"candidatesTokensDetails": [ # Per-modality breakdown of response tokens for this invocation. Includes the model's text output, function calls, or final answer. Does not include thought tokens.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"promptTokensDetails": [ # Per-modality breakdown of prompt tokens for this invocation. Includes all tokens sent to the model: user content, system instructions, formatting/control tokens, tool declarations, and any previous-turn context accumulated during tool use.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"thoughtsTokensDetails": [ # Per-modality breakdown of thought tokens for this invocation (for thinking models). Includes auxiliary control tokens produced by the model that delimit thought blocks.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
},
],
"outputTokensByModality": [ # A breakdown of output token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"rawPromptToken": 42, # Output only.
"toolCallUsage": [ # Output only. Per-tool call statistics, sorted by (`tool_type`, `name`).
{ # Usage statistics for one tool, aggregated over the interaction.
"name": "A String", # The function name as declared in the request. Set only when `tool_type` is TOOL_TYPE_FUNCTION; empty for all other tool types.
"serverExecutedCount": 42, # Of `tool_call_count`, calls dispatched to and run by the server, whether or not they succeeded.
"toolCallCount": 42, # Number of calls to this tool that the model generated.
"toolType": "A String",
},
],
"toolUseTokensByModality": [ # A breakdown of tool-use token usage by modality.
{ # The token count for a single response modality.
"modality": "A String", # The modality associated with the token count.
"tokens": 42, # Number of tokens for the modality.
},
],
"totalCachedTokens": 42, # Number of tokens in the cached part of the prompt (the cached content).
"totalInputTokens": 42, # Number of tokens in the prompt (context).
"totalModelInvocations": 42, # Total number of LLM model invocations executed during the interaction turn (including retries and multi-step tool loop calls).
"totalOutputTokens": 42, # Total number of tokens across all the generated responses.
"totalThoughtTokens": 42, # Number of tokens of thoughts for thinking models.
"totalTokens": 42, # Total token count for the interaction request (prompt + responses + other internal tokens).
"totalToolUseTokens": 42, # Number of tokens present in tool-use prompt(s).
},
"taskUpdate": { # A change to a task's details. Surfaces out the Task resource fields that change during execution. # A change to the task's details.
"updates": [ # The task detail changes carried by this event.
{ # A single task detail change.
"summary": "A String", # Rolling progress/outcome summary.
"title": "A String", # Concise title.
},
],
},
"timestampMicros": "A String", # Strictly increasing generation timestamp, in unix micros.
"trajectoryId": "A String", # Optional. The runtime trajectory UUID that produced this event's step, e.g. "e9df8df3-d63a-4747-ad00-eaef837d7d31". A debugging correlation handle and the join key to the runtime's per-step trajectory record (for Sobi, the Trajectory Store viewer at sobi.corp.google.com/trajectory/). Set on the step-bearing events (`step` and the `step_start` of a streamed step); empty on status_changed / artifacts_changed and on the step_delta/step_stop frames continuing a run (correlate those by `index` with their step_start). Also empty on steps the Sobi converter did not build: the actor delivers `elicitation_call` as a native `Step` payload with no field 110, and `Session::ReadConverted` forwards it unchanged (`jetski_to_interaction_stream_converter.cc:1101-1104`), so a HITL turn reaches the client on `step` with `trajectory_id` empty even though a trajectory does exist for it. A whole turn shares one trajectory id. The server never derives behavior from it. See b/552010818.
},
],
"taskCompleted": { # Signals that the task reached a terminal status. # The task reached a terminal status.
},
"taskCreated": { # Server reply confirming a new task was created. # Reply to create_task: returns the new task name.
"clientId": "A String", # The client identifier bound to this stream connection (either echoed from CreateTaskEvent or server-generated). Use this ID in SubscribeTaskEvent to resume after a disconnect.
"task": "A String", # Resource name of the created task. The client uses this id to reconnect (via a subscribe_task connect request) after a dropped stream. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task}
},
"taskSubscribed": { # Server reply confirming subscription to an existing task. # Reply to subscribe_task.
"clientId": "A String", # The client identifier bound to this stream connection (either echoed from SubscribeTaskEvent or server-generated). Use this ID in subsequent SubscribeTaskEvent messages to maintain sequence continuity.
"nextStepSeqNum": "A String", # The next step sequence number the server will send: the position it resolved to from the subscribe request. The mirror of the same-named field on SubscribeTaskEvent -- there it is what the client asks for, here it is what the server settled on. Zero means no cursor was resolved: the request supplied neither next_step_seq_num nor ack_output_seq_num, so output replays from the oldest retained step.
"status": "A String", # The current coarse status of the task at subscription time.
},
}
suspend(name, body=None, x__xgafv=None)
Suspends a task, pausing its active turn or scheduling loop and transitioning the status to SUSPENDED. The underlying runtime session remains resumable.
Args:
name: string, Required. The name of the task to suspend. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
body: object, The request body.
The object takes the form of:
{ # Request for TaskService.SuspendTask.
"operateOnSelf": True or False, # Optional. Whether to skip cascade suspension to all descendant subtasks. Defaults to false (cascades to all descendants by default).
"statusDetail": { # Why a task is in its current status, when the status alone is not enough to act on (today: `SUSPENDED`). Clients MUST treat an unrecognized `StatusReason` as an opaque block. Copied to the DB mirror by name and number, so a field or enum value added here without the matching DB-side addition is silently dropped on write. LINT.IfChange(status_detail) # Optional. Machine-readable reason and detail for the suspension.
"detail": "A String", # Optional human-readable explanation, so a surface can render something without its own StatusReason -> string table. Not localized; clients needing localization should render from `reason` instead. Not a `google.rpc.Status`: RPC codes do not map onto lifecycle states, and `TaskOutcome.status` already covers terminal failures.
"reason": "A String", # Machine-readable reason. Clients switch on this to pick a recovery affordance (upsell CTA, admin contact, retry).
},
}
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # This resource represents a long-running operation that is the result of a network API call.
"done": True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
"metadata": { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
"name": "A String", # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
"response": { # The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
}
upload(name, body=None, media_body=None, media_mime_type=None, x__xgafv=None)
Uploads a file. The file is sent as media: post it to this method's URL with an `/upload` prefix, e.g. `/upload/v1beta1/{name}:upload`, carrying `path` as request metadata and the file's bytes as the media content. The task must not be in a terminal state, and an existing file at `path` is replaced. At most 10 GiB.
Args:
name: string, Required. The task or collaborative project to upload to. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} or projects/{project}/locations/{location}/collaborativeProjects/{collaborative_project} (required)
body: object, The request body.
The object takes the form of:
{ # Request for ArtifactService.UploadArtifact.
"path": "A String", # Required. Absolute destination path in the task's workspace, e.g. `/workspace/userdata/input.csv`, or, for a collaborative project, under `/workspace/project`, e.g. `/workspace/project/report.md`. Must be under `/workspace` and at most 1024 characters; relative paths and paths containing a `..` segment are rejected with `INVALID_ARGUMENT`.
}
media_body: string, The filename of the media request body, or an instance of a MediaUpload object.
media_mime_type: string, The MIME type of the media request body, or an instance of a MediaUpload object.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Response for ArtifactService.UploadArtifact.
"path": "A String", # The file's path in the task's workspace.
}
uploadArtifact(task, body=None, path=None, x__xgafv=None)
Uploads a file into a task's workspace. A client-streaming RPC: the request body is the file's raw bytes, relayed to storage a chunk at a time, so neither ESF nor this server holds the whole file. A broken connection restarts the upload from zero. `path` must be an absolute path under `/workspace/userdata/`. The task must not be in a terminal state. An existing file at `path` is replaced. At most 1 GiB.
Args:
task: string, Required. The task to upload into. Format: projects/{project}/locations/{location}/agents/{agent}/tasks/{task} (required)
body: object, The request body.
The object takes the form of:
{ # Message that represents an arbitrary HTTP body. It should only be used for payload formats that can't be represented as JSON, such as raw binary or an HTML page. This message can be used both in streaming and non-streaming API methods in the request as well as the response. It can be used as a top-level request field, which is convenient if one wants to extract parameters from either the URL or HTTP template into the request fields and also want access to the raw HTTP body. Example: message GetResourceRequest { // A unique request id. string request_id = 1; // The raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } service ResourceService { rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); } Example with streaming methods: service CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); } Use of this type only changes how the request and response bodies are handled, all other features will continue to work unchanged.
"contentType": "A String", # The HTTP Content-Type header value specifying the content type of the body.
"data": "A String", # The HTTP request/response body as raw binary.
"extensions": [ # Application specific response metadata. Must be set in the first response for streaming APIs.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
}
path: string, Required. Absolute destination path, e.g. "/workspace/userdata/input.csv". Must be under "/workspace/userdata/" and at most 1024 characters; relative paths and paths containing a ".." segment are rejected with INVALID_ARGUMENT.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A file or directory in a task's workspace.
"mimeType": "A String", # Output only. The detected media type. Empty for directories.
"path": "A String", # Output only. Absolute path in the task's sandbox, e.g. "/workspace/userdata/input.csv" or "/workspace/report.md". Always under "/workspace" and never contains "..". Can be passed as-is to DownloadTaskArtifact.
"sizeBytes": "A String", # Output only. Size of the file in bytes. Zero for directories.
"type": "A String", # Output only. Whether this entry is a file or a directory.
"updateTime": "A String", # Output only. Last modification time of the file as it was read: the sandbox's when read from a running sandbox, otherwise the stored object's.
}