What structural signals indicate a capability-negotiation downgrade in A2A v1.0 signed agent cards, and why the downgrade is invisible to the delegating agent

**Date of Record:** 2026 December 2 **Scope:** Applies to A2A v1.0 task delegation where the callee advertises a signed Agent Card whose `capabilities` and `skills` blocks are negotiated per-task. Does not apply to static capability manifests or to MCP tool-schema negotiation, which has a different binding model.

Core Distinction

A signed Agent Card is a *claim about the agent's envelope*, not a *claim about the specific task instance*. The card's signature attests that the publisher of the card authored the `capabilities` set at signing time. It does not attest that the callee will honor every capability for the specific delegated task, nor that the sub-capability the caller actually needs (e.g., a particular `inputModes`, a specific `skill.id` with a required `extensions` field) survives the callee's internal routing.

The failure mode is this: **the caller validates the card signature, sees the capability it needs in the advertised set, delegates, and receives a successful task response — but the callee silently downgraded to a fallback path because the *task-scoped* capability selection failed internally.** The signature is valid, the task status is `completed`, and the degradation is structurally invisible in the A2A response envelope.

This is not a signature-verification failure. It is a **capability-scope conflation** failure: the card's signed capability set and the task's effective capability set are different objects, and A2A v1.0 provides no mandatory field that reports the delta between them.

What Was Observed

A delegating orchestrator agent (`caller`) holds a cached, signature-verified Agent Card for a `callee`. The card advertises:

The caller's signature check passes against the callee's published JWKS. The caller delegates a PDF table-extraction task with `inputModes: ["application/pdf"]` and a required `extensions: { "table.structure": "v2" }` hint.

The callee's internal router receives the task. Its `doc.extract.tables` handler supports `table.structure: v2`, but the callee's *task admission layer* — a separate component from the skill handler — does not recognize the `table.structure` extension key because it was added to the skill's contract after the card was signed but the admission layer's allowlist was not updated. The admission layer strips unknown extension keys (a defensive default) and routes the task to the skill handler anyway, because the skill `id` matched.

The skill handler, now missing the `table.structure` hint, falls back to `v1` table extraction: it returns a flat list of cell strings with no row/column structure.

The A2A response is:

status: "completed"
artifacts: [{ parts: [{ kind: "data", data: { tables: ["cell1","cell2",...] } }] }]

The caller receives a `completed` task with a JSON artifact that superficially matches `outputModes: ["application/json"]`. The caller's schema check passes (it's valid JSON). The caller's *semantic* check — "does this artifact contain structured tables?" — is not part of A2A and is not performed. The caller records success.

Three days later, a downstream consumer of the caller's output fails because it expected `{rows, cols, cells}` and received a flat array. The failure is attributed to the caller, not the callee. The callee's logs show `completed`. The card signature is still valid.

The structural signal that would have caught this — the callee's admission layer stripping the extension — is **not propagated to the A2A response envelope**. A2A v1.0's `TaskStatus` has no `degraded` state and no `effectiveCapabilities` field. The only signal is the artifact's shape, which requires semantic validation the caller did not perform because the card said the capability was present.

Condition of Validity

This failure requires all of the following to hold simultaneously:

  1. **The card is signed but the task-admission layer is not covered by the signature.** The signature covers the card's `capabilities` and `skills` blocks as published. It does not cover the callee's internal routing table, admission allowlist, or extension-key handling. Any divergence between the signed card and the admission layer's effective behavior is outside the signature's scope.
  1. **The capability the caller needs is expressed as an extension or sub-field, not as a top-level skill `id`.** Top-level skill `id` matching is robust because the admission layer routes on it. Extension keys (`extensions`, `inputModes` sub-values, `outputModes` sub-values) are advisory in most implementations and are stripped or ignored by defensive admission layers.
  1. **The callee's fallback path is *shape-compatible* with the requested path.** If the fallback returned a different `outputModes` (e.g., `text/plain` instead of `application/json`), the caller's mode check would catch it. The failure is invisible precisely because the fallback returns the *same MIME type* with a *different semantic structure*.
  1. **The caller does not perform post-hoc semantic validation of the artifact against the requested extension.** If the caller validates `data.tables` is a list of `{rows, cols, cells}` objects, the downgrade is caught. If the caller only validates `data` is valid JSON, it is not.

When any of these does not hold, the downgrade is either caught or does not occur. The boundary is the intersection of all four.

Decision Boundary

The decision the caller must make is: **treat card-advertised capability as sufficient, or treat it as necessary-but-not-sufficient and require an explicit effective-capability echo in the response.**

A2A v1.0 does not mandate the echo. The caller's options:

The boundary condition: **Option C is the only option that is both protocol-compliant and callee-independent, but it only works if the caller pins the extension contract version at delegation time and validates against that pinned version, not against the card's advertised (possibly stale) version.**

The concrete invariant the caller must enforce:

> For every delegation that carries an `extensions` key, the caller MUST validate the returned artifact against the extension contract version it *sent*, not against the version the card advertised. If the caller cannot validate (unknown extension schema), it MUST NOT treat `completed` as success.

This is the "pinned-extension invariant." It bounds the downgrade because it makes the caller's acceptance criterion depend on the caller's own contract knowledge, not on the callee's admission-layer behavior — which the signature does not cover.

Operational Effect

Enforcing the pinned-extension invariant changes the caller's failure surface from "silent semantic downgrade" to "explicit contract-mismatch rejection." The operational effects:

  1. **Delegation latency increases** because the caller performs schema validation on the artifact, not just MIME-type validation. For structured-output extensions, this is a JSON-schema check per artifact; for large artifacts, this is non-trivial.
  1. **False rejections increase** when the callee returns a *superset* of the pinned contract (e.g., adds fields the caller did not request). The caller must validate "contains the pinned required fields" rather than "matches exactly," or it will reject valid responses.
  1. **The card cache staleness problem becomes visible.** When the caller pins an extension version and the callee's card advertises a newer version, the caller's pinned validation will fail against the newer callee's output. This is the *correct* behavior — it surfaces the card/contract drift — but it means card cache TTL and extension-contract version pinning must be managed together. A caller with a 24h card cache and a pinned extension v2 will reject a callee that upgraded to v3 mid-cache-window, which is correct but operationally noisy.
  1. **Audit trail gains a rejection reason.** Rejected delegations carry `CONTRACT_MISMATCH` rather than `completed`, which means the callee's downgrade is now visible in the caller's logs even though the callee still reports `completed`. The two logs disagree, which is the signal that the admission layer and the card have diverged.
  1. **The callee's admission-layer stripping is no longer invisible.** It is still not reported by the callee, but it is *detected* by the caller via artifact validation. The detection is caller-side and does not require protocol changes.

The invariant does not prevent the downgrade. It prevents the downgrade from being *silently accepted*. The callee still strips the extension; the caller now knows.

import json
from typing import Any, Mapping

class CapabilityDowngradeError(RuntimeError):
    """Raised when a completed A2A task's artifact does not satisfy the
    extension contract the caller pinned at delegation time."""
    pass

class ExtensionContractUnknownError(CapabilityDowngradeError):
    """Raised when the caller cannot validate because it has no pinned
    schema for the extension it requested."""
    pass

def validate_pinned_artifact(
    artifact: Mapping[str, Any],
    pinned_extension: str,
    pinned_version: str,
    pinned_schema: Mapping[str, Any] | None,
) -> None:
    """
    Enforce the pinned-extension invariant on an A2A task artifact.

    The caller MUST validate against the contract version it SENT, not the
    version the callee's card advertised. If the caller has no schema for
    the pinned version, it MUST NOT treat 'completed' as success.
    """
    if pinned_schema is None:
        raise ExtensionContractUnknownError(
            f"No pinned schema for extension {pinned_extension!r} "
            f"version {pinned_version!r}; cannot validate artifact. "
            f"Refusing to accept 'completed' as success."
        )

    data = artifact.get("data")
    if data is None:
        raise CapabilityDowngradeError(
            f"Artifact for {pinned_extension!r}@{pinned_version} has no "
            f"'data' field; cannot validate against pinned contract."
        )

    required = pinned_schema.get("required", [])
    missing = [k for k in required if k not in data]
    if missing:
        raise CapabilityDowngradeError(
            f"Artifact for {pinned_extension!r}@{pinned_version} is missing "
            f"required fields {missing!r}; callee likely downgraded to a "
            f"shape-compatible fallback (admission layer stripped extension). "
            f"Card signature remains valid; downgrade is callee-internal."
        )

    # Type check on required fields (shallow; deep validation omitted for brevity)
    props = pinned_schema.get("properties", {})
    for field in required:
        expected = props.get(field, {}).get("type")
        if expected == "array" and not isinstance(data[field], list):
            raise CapabilityDowngradeError(
                f"Artifact field {field!r} expected array for "
                f"{pinned_extension!r}@{pinned_version}, got "
                f"{type(data[field]).__name__}; downgrade suspected."
            )
        if expected == "object" and not isinstance(data[field], dict):
            raise CapabilityDowngradeError(
                f"Artifact field {field!r} expected object for "
                f"{pinned_extension!r}@{pinned_version}, got "
                f"{type(data[field]).__name__}; downgrade suspected."
            )

def accept_a2a_response(
    response: Mapping[str, Any],
    pinned_extension: str,
    pinned_version: str,
    pinned_schema: Mapping[str, Any] | None,
) -> None:
    status = response.get("status", {}).get("state")
    if status != "completed":
        return  # non-completed handled elsewhere

    artifacts = response.get("artifacts") or []
    if not artifacts:
        raise CapabilityDowngradeError(
            f"Task reported 'completed' but returned no artifacts for "
            f"{pinned_extension!r}@{pinned_version}."
        )

    for artifact in artifacts:
        validate_pinned_artifact(
            artifact, pinned_extension, pinned_version, pinned_schema
        )