A wrapper object used in streaming operations to encapsulate different types of response data.
| JSON representation |
|---|
{ // Union field |
| Fields | |
|---|---|
Union field payload. The payload of the stream response. payload can be only one of the following: |
|
task |
A Task object containing the current state of the task. |
message |
A Message object containing a message from the agent. |
statusUpdate |
An event indicating a task status update. |
artifactUpdate |
An event indicating a task artifact update. |
TaskStatusUpdateEvent
An event sent by the agent to notify the client of a change in a task's status.
| JSON representation |
|---|
{
"taskId": string,
"contextId": string,
"status": {
object ( |
| Fields | |
|---|---|
taskId |
Required. The ID of the task that has changed. |
contextId |
Required. The ID of the context that the task belongs to. |
status |
Required. The new status of the task. |
metadata |
Optional. Metadata associated with the task update. |
TaskArtifactUpdateEvent
A task delta where an artifact has been generated.
| JSON representation |
|---|
{
"taskId": string,
"contextId": string,
"artifact": {
object ( |
| Fields | |
|---|---|
taskId |
Required. The ID of the task for this artifact. |
contextId |
Required. The ID of the context that this task belongs to. |
artifact |
Required. The artifact that was generated or updated. |
append |
If true, the content of this artifact should be appended to a previously sent artifact with the same ID. |
lastChunk |
If true, this is the final chunk of the artifact. |
metadata |
Optional. Metadata associated with the artifact update. |