Skip to main content
canceledTerminal

canceled is the terminal state after a successful tasks/cancel call. The agent stopped execution without completing the task. No partial results are available. Either the client or the server initiated the cancellation.

Description

canceled means the task was stopped before completing. Either the client explicitly called tasks/cancel, or the server canceled the task due to policy (timeout, resource limits, shutdown).

The A2A spec allows both client-initiated and server-initiated cancellation. When a client calls tasks/cancel, the server transitions the task to canceled as quickly as possible, but there is no guarantee that partial execution effects are rolled back – the agent may have already taken external actions.

Like completed and failed, canceled is immutable and terminal. Polling a canceled task returns the canceled state indefinitely until the server's retention window expires.

Terminal state

Once a task reaches canceled, its state is immutable. tasks/cancel will return an error on a task in this state.

All Task States