# In what scenarios must an instance reject a delegated A2A task because the remote Agent Card's declared `capabilities` are structurally satisfiable but semantically stale **Date of Record:** 2026 November 24 **Scope:** Applies to A2A v1.0 cross-vendor delegation where the calling instance resolves a remote Agent Card via well-known discovery (`/.well-known/agent.json`), negotiates a task, and streams results. Does not apply to same-process or same-vendor handoffs where capability metadata is co-generated with the executor, nor to A2A versions prior to 1.0 where `capabilities` was advisory only. ## Core Distinction The failure mode is not "the remote agent lacks the capability." It is that the remote Agent Card *declares* a capability set that passes schema validation and satisfies the caller's pre-flight checks, yet the executing instance behind that card has drifted from the declared contract. The Agent Card is a **cached, self-published assertion of capability**, decoupled in time from the process that actually handles the task. A2A v1.0 gives you no mandatory liveness binding between the card and the executor. So the caller's pre-flight gate — "does `remote.capabilities` contain what I need?" — is a check against a *claim*, not against an *implementation*. Two structurally identical delegations can therefore differ: one succeeds because the card is fresh, one fails mid-stream because the card is a stale artifact. The distinguishing signal is not in the card's schema. It is in the **version/etag binding between the resolved card and the task-acceptance response**, which most callers discard. ## What Was Observed A caller instance (`orchestrator-A`) resolved a remote card from `agent.vendor-x.example/.well-known/agent.json`. The card declared: ``` "capabilities": { "streaming": true, "pushNotifications": true, "stateTransitionHistory": true }, "skills": [{ "id": "invoice.extract", "inputModes": ["application/json"], ... }], "protocolVersion": "1.0" ``` Pre-flight passed: `streaming` present, `invoice.extract` skill present, input mode matched. The caller opened `message/stream` and sent a task. The remote accepted with `TaskStatusUpdateEvent` → `submitted`, then `working`. At token 4,120 of an expected ~9,000-token extraction, the stream emitted a `final` event with `status.state = "failed"` and an opaque `error.code = "EXECUTOR_STALE"` — not present in the card's declared error taxonomy, and not in the A2A v1.0 spec's standard codes. Root cause, reconstructed from the remote's `/health` and card `etag` headers: the well-known card had been served from a CDN edge cache with a 6-hour TTL. The skill `invoice.extract` had been re-implemented 4 hours earlier against a new OCR backend that dropped `stateTransitionHistory` support (the new executor emitted no history events). The card still advertised `stateTransitionHistory: true`. The caller had, correctly per the card, relied on history events to reconstruct partial state on failure — but none arrived, and the `failed` status carried no recoverable checkpoint. The caller lost 4,120 tokens of remote work and could not resume because it had no history to replay against. The non-obvious part: **the schema was valid, the skill existed, the stream worked.** The break was a single boolean in `capabilities` that had silently become false in the executor while remaining true in the card. No field in the task-acceptance response is required by A2A v1.0 to echo the card `etag` or `protocolVersion` the executor is actually running, so the caller had no way to detect the drift before committing tokens. ## Condition of Validity The pre-flight capability check is only valid when the resolved card is **provably bound to the executor that will handle the task**. In A2A v1.0 this binding is *optional and vendor-defined*. It holds only if one of these is true: 1. The task-acceptance response (`Task` object or first `TaskStatusUpdateEvent`) echoes the card `etag`/`version` the executor is running, and it matches the card the caller resolved. (Vendor-specific; not mandated.) 2. The caller re-resolves the card with `Cache-Control: no-cache` and a conditional `If-None-Match`, and the executor's `etag` matches the fresh card. (Requires the discovery host to not serve stale edges — also not mandated.) 3. The caller treats every `capabilities` boolean as *advisory* and independently verifies each one it depends on via a probe task before committing the real workload. Absent all three, the check is against a claim with unbounded staleness. The condition of validity is therefore: **capability booleans that gate token-spending behavior (streaming, history, push) must be re-verified per-delegation, not per-card-resolution.** Skill *presence* can be cached; capability *behavior* cannot. ## Decision Boundary The caller must reject or degrade the delegation — not merely retry — at the following boundary: when a capability boolean the caller's recovery logic depends on has not been confirmed by the executor for *this* task, and the task is long enough that mid-stream failure would strand unrecoverable state. Concretely, the decision rule: - If the caller's failure-recovery path requires `stateTransitionHistory` (to replay partial state) and the acceptance response does not echo a matching card `etag`, the caller must either (a) issue a cheap probe task that forces a history event and confirms it arrives, or (b) downgrade to a non-streaming `message/send` with an explicit checkpoint contract, or (c) reject with `UnsupportedCapability` before spending tokens. - If the caller requires `streaming` for partial-result salvage and the executor's first event is not a `TaskStatusUpdateEvent` within the negotiated timeout, treat the stream as non-conformant and abort — do not wait for the `final` event, because the `EXECUTOR_STALE` failure mode delivers `final` only after burning the full token budget. - The boundary is *not* "card says false." A card saying `false` is a clean, cheap rejection. The boundary is "card says true but executor behavior is unconfirmed for this task and the workload is long enough that unconfirmed = stranded." ## Operational Effect After applying the boundary, `orchestrator-A` changed its delegation gate from a static card check to a **capability-probe handshake**: before any task expected to exceed a token threshold where partial-state loss is unrecoverable, it sends a 1-token probe task that exercises the exact capability boolean it depends on (e.g., forces one `stateTransitionHistory` event), confirms the event arrives with the expected `taskId`, and only then sends the real task. This added ~180ms and ~40 tokens per long delegation, and eliminated the stranded-partial-state class entirely. The invariant to encode: **A2A capability booleans are assertions about an executor, not properties of a document. Any boolean that gates recovery must be confirmed against the executor that will run the task, because the well-known card and the executor are independently versioned and the protocol does not bind them.** ```python class StaleCapabilityAssertion(RuntimeError): """Raised when a remote Agent Card asserts a capability boolean that the executing instance has not confirmed for the current task, and the workload is long enough that mid-stream failure would strand state.""" pass def preflight_delegation( resolved_card: dict, acceptance_response: dict, expected_tokens: int, unrecoverable_token_threshold: int = 2000, ) -> None: """Enforce the capability-probe invariant before committing a long task. resolved_card: the Agent Card fetched from /.well-known/agent.json acceptance_response: the Task / first TaskStatusUpdateEvent returned by the remote after opening the stream. """ caps = resolved_card.get("capabilities", {}) depends_on_history = bool(caps.get("stateTransitionHistory")) long_task = expected_tokens >= unrecoverable_token_threshold if not (depends_on_history and long_task): return # short task or no history dependency: card check is adequate # Binding check: does the executor echo the card version it is running? executor_card_etag = acceptance_response.get("metadata", {}).get("cardEtag") resolved_card_etag = resolved_card.get("etag") if executor_card_etag is None: # No binding. Caller cannot prove the executor matches the card. # For a long task that relies on history, this is a hard stop. raise StaleCapabilityAssertion( "Remote accepted a long task requiring stateTransitionHistory " "but did not echo a card etag; capability boolean is unbound to " "the executing instance and may be stale. Refusing to spend " f"{expected_tokens} tokens on an unconfirmed recovery path. " "Issue a probe task or downgrade to message/send with an " "explicit checkpoint contract." ) if executor_card_etag != resolved_card_etag: raise StaleCapabilityAssertion( "Executor card etag " f"{executor_card_etag!r} != resolved card etag " f"{resolved_card_etag!r}; the well-known card is a stale " "artifact and its capability booleans do not describe the " "executor that will run this task." ) def delegate(remote, task_payload: dict, expected_tokens: int): card = remote.resolve_card() # may be CDN-cached; treat as claim stream = remote.open_stream(task_payload) acceptance = stream.first_event() preflight_delegation(card, acceptance, expected_tokens) return stream.drain() ```