Skip to content

Commit 40d6286

Browse files
madankumarpichamuthumuscariellodarrelmiller
authored
refactor(spec)!: Move extendedAgentCard field to AgentCapabilities (#1307)
Relocates `supports_extended_agent_card` from AgentCard to AgentCapabilities for architectural consistency. All optional features that enable specific operations now reside in the capabilities object. Rationale: - Consistent placement: streaming, push_notifications, and state_transition_history are all in AgentCapabilities - Improved discoverability: developers naturally check capabilities for optional features - Semantic correctness: extended agent card support is a capability Changes: - Proto: Removed field 13 from AgentCard, added field 5 to AgentCapabilities - Field renamed: supports_extended_agent_card → extended_agent_card - Updated all references: AgentCard.supportsExtendedAgentCard → AgentCard.capabilities.extendedAgentCard - Updated JSON examples to reflect new structure - Added migration guidance in Appendix A.2.2 of specification Breaking change: Clients and agents must update capability checking logic. See specification Appendix A.2.2 for migration steps. Fixes #1229 --------- Co-authored-by: Luca Muscariello <[email protected]> Co-authored-by: Darrel <[email protected]>
1 parent 0e204bf commit 40d6286

File tree

3 files changed

+78
-12
lines changed

3 files changed

+78
-12
lines changed

docs/llms.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,10 @@ Key features of the A2A protocol include: agent discovery via Agent Cards, stand
4242
- `name`, `description`, `version`: (string) Agent's identity.
4343
- `url`: (string) The preferred endpoint URL for the agent's A2A service.
4444
- `provider`: (`AgentProvider`) Organization details.
45-
- `capabilities`: (`AgentCapabilities`) Features supported (streaming, push notifications, extensions).
45+
- `capabilities`: (`AgentCapabilities`) Features supported (streaming, push notifications, state transition history, extended agent card, extensions).
4646
- `securitySchemes`, `security`: (object, array) Authentication and authorization requirements, following OpenAPI specifications.
4747
- `defaultInputModes`, `defaultOutputModes`: (string[]) Default supported MIME types.
4848
- `skills`: (`AgentSkill[]`) List of specific capabilities.
49-
- `supportsExtendedAgentCard`: (boolean) Indicates if a more detailed card is available post-authentication.
5049
- `signatures`: (`AgentCardSignature[]`) JWS signatures for verifying the card's integrity.
5150
- **`AgentSkill`:** A specific capability of an agent, with `id`, `name`, `description`, `tags`, and `examples`.
5251
- **`Task`:** Represents a stateful unit of work.

docs/specification.md

Lines changed: 75 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ The operation MUST permanently remove the specified push notification configurat
417417

418418
#### 3.1.11. Get Extended Agent Card
419419

420-
Retrieves a potentially more detailed version of the Agent Card after the client has authenticated. This endpoint is available only if `AgentCard.supportsExtendedAgentCard` is `true`.
420+
Retrieves a potentially more detailed version of the Agent Card after the client has authenticated. This endpoint is available only if `AgentCard.capabilities.extendedAgentCard` is `true`.
421421

422422
**Inputs:**
423423

@@ -437,7 +437,7 @@ Retrieves a potentially more detailed version of the Agent Card after the client
437437
- **Authentication**: The client MUST authenticate the request using one of the schemes declared in the public `AgentCard.securitySchemes` and `AgentCard.security` fields.
438438
- **Extended Information**: The operation MAY return different details based on client authentication level, including additional skills, capabilities, or configuration not available in the public Agent Card.
439439
- **Card Replacement**: Clients retrieving this extended card SHOULD replace their cached public Agent Card with the content received from this endpoint for the duration of their authenticated session or until the card's version changes.
440-
- **Availability**: This operation is only available if the public Agent Card declares `supportsExtendedAgentCard: true`.
440+
- **Availability**: This operation is only available if the public Agent Card declares `capabilities.extendedAgentCard: true`.
441441

442442
For detailed security guidance on extended agent cards, see [Section 13.3 Extended Agent Card Access Control](#133-extended-agent-card-access-control).
443443

@@ -586,7 +586,7 @@ Agents declare optional capabilities in their [`AgentCard`](#441-agentcard). Whe
586586

587587
- **Push Notifications**: If `AgentCard.capabilities.pushNotifications` is `false` or not present, operations related to push notification configuration (Set, Get, List, Delete) **MUST** return [`PushNotificationNotSupportedError`](#332-error-handling).
588588
- **Streaming**: If `AgentCard.capabilities.streaming` is `false` or not present, attempts to use `SendStreamingMessage` or `SubscribeToTask` operations **MUST** return [`UnsupportedOperationError`](#332-error-handling).
589-
- **Extended Agent Card**: If `AgentCard.supportsExtendedAgentCard` is `false` or not present, attempts to call the Get Extended Agent Card operation **MUST** return [`UnsupportedOperationError`](#332-error-handling). If the agent declares support but has not configured an extended card, it **MUST** return [`ExtendedAgentCardNotConfiguredError`](#332-error-handling).
589+
- **Extended Agent Card**: If `AgentCard.capabilities.extendedAgentCard` is `false` or not present, attempts to call the Get Extended Agent Card operation **MUST** return [`UnsupportedOperationError`](#332-error-handling). If the agent declares support but has not configured an extended card, it **MUST** return [`ExtendedAgentCardNotConfiguredError`](#332-error-handling).
590590
- **Extensions**: When a client requests use of an extension marked as `required: true` in the Agent Card but the client does not declare support for it, the agent **MUST** return [`ExtensionSupportRequiredError`](#332-error-handling).
591591

592592
Clients **SHOULD** validate capability support by examining the Agent Card before attempting operations that require optional capabilities.
@@ -1834,7 +1834,9 @@ Host: example.com
18341834

18351835
```json
18361836
{
1837-
"supportsExtendedAgentCard": true,
1837+
"capabilities": {
1838+
"extendedAgentCard": true
1839+
},
18381840
"securitySchemes": {
18391841
"google": {
18401842
"openIdConnectSecurityScheme": {
@@ -2108,7 +2110,8 @@ Clients verifying Agent Card signatures **MUST**:
21082110
"capabilities": {
21092111
"streaming": true,
21102112
"pushNotifications": true,
2111-
"stateTransitionHistory": false
2113+
"stateTransitionHistory": false,
2114+
"extendedAgentCard": true
21122115
},
21132116
"securitySchemes": {
21142117
"google": {
@@ -2154,7 +2157,6 @@ Clients verifying Agent Card signatures **MUST**:
21542157
]
21552158
}
21562159
],
2157-
"supportsExtendedAgentCard": true,
21582160
"signatures": [
21592161
{
21602162
"protected": "eyJhbGciOiJFUzI1NiIsInR5cCI6IkpPU0UiLCJraWQiOiJrZXktMSIsImprdSI6Imh0dHBzOi8vZXhhbXBsZS5jb20vYWdlbnQvandrcy5qc29uIn0",
@@ -3114,8 +3116,8 @@ The extended Agent Card feature allows agents to provide additional capabilities
31143116

31153117
**Availability Declaration:**
31163118

3117-
- Agents declare extended card support via `AgentCard.supportsExtendedAgentCard`
3118-
- When `supportsExtendedAgentCard` is `false` or not present, the operation **MUST** return [`UnsupportedOperationError`](#332-error-handling)
3119+
- Agents declare extended card support via `AgentCard.capabilities.extendedAgentCard`
3120+
- When `capabilities.extendedAgentCard` is `false` or not present, the operation **MUST** return [`UnsupportedOperationError`](#332-error-handling)
31193121
- When support is declared but no extended card is configured, the operation **MUST** return [`ExtendedAgentCardNotConfiguredError`](#332-error-handling)
31203122

31213123
See also: [Section 3.1.11 Get Extended Agent Card](#3111-get-extended-agent-card) and [Section 3.3.4 Capability Validation](#334-capability-validation).
@@ -3480,6 +3482,71 @@ This change aligns with modern API design practices and Protocol Buffers' `oneof
34803482
- Eliminates the need for representing inheritance structures in schema languages
34813483
- Improves type safety in strongly-typed languages
34823484

3485+
#### A.2.2 Breaking Change: Extended Agent Card Field Relocated
3486+
3487+
**Version 1.0 relocates the extended agent card capability** from a top-level field to the capabilities object for architectural consistency.
3488+
3489+
**Legacy Structure (pre-1.0):**
3490+
3491+
```json
3492+
{
3493+
"supportsExtendedAgentCard": true,
3494+
"capabilities": {
3495+
"streaming": true
3496+
}
3497+
}
3498+
```
3499+
3500+
**Current Structure (1.0+):**
3501+
3502+
```json
3503+
{
3504+
"capabilities": {
3505+
"streaming": true,
3506+
"extendedAgentCard": true
3507+
}
3508+
}
3509+
```
3510+
3511+
**Proto Changes:**
3512+
3513+
- Removed: `AgentCard.supports_extended_agent_card` (field 13)
3514+
- Added: `AgentCapabilities.extended_agent_card` (field 5)
3515+
3516+
**Migration Steps:**
3517+
3518+
For **Agent Implementations**:
3519+
3520+
1. Remove `supportsExtendedAgentCard` from top-level AgentCard
3521+
2. Add `extendedAgentCard` to `capabilities` object
3522+
3. Update validation: `agentCard.capabilities?.extendedAgentCard`
3523+
3524+
For **Client Implementations**:
3525+
3526+
1. Update capability checks: `agentCard.capabilities?.extendedAgentCard`
3527+
2. Temporary fallback (transition period):
3528+
3529+
```javascript
3530+
const supported = agentCard.capabilities?.extendedAgentCard ||
3531+
agentCard.supportsExtendedAgentCard;
3532+
```
3533+
3534+
3. Remove fallback after agent ecosystem migrates
3535+
3536+
For **SDK Developers**:
3537+
3538+
1. Regenerate code from updated proto
3539+
2. Update type definitions
3540+
3. Document breaking change in release notes
3541+
3542+
**Rationale:**
3543+
3544+
All optional features enabling specific operations (`streaming`, `pushNotifications`, `stateTransitionHistory`) reside in `AgentCapabilities`. Moving `extendedAgentCard` achieves:
3545+
3546+
- Architectural consistency
3547+
- Improved discoverability
3548+
- Semantic correctness (it is a capability)
3549+
34833550
### A.3 Future Automation
34843551
34853552
Once the proto→schema generation pipeline lands, this appendix will be partially auto-generated (legacy mapping table sourced from a maintained manifest). Until then, edits MUST be manual and reviewed in PRs affecting `a2a.proto`.

specification/grpc/a2a.proto

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -449,8 +449,6 @@ message AgentCard {
449449
// a descriptive concept but represents a more focused set of behaviors that the
450450
// agent is likely to succeed at.
451451
repeated AgentSkill skills = 12 [(google.api.field_behavior) = REQUIRED];
452-
// Whether the agent supports providing an extended agent card when authenticated.
453-
optional bool supports_extended_agent_card = 13;
454452
// JSON Web Signatures computed for this AgentCard.
455453
repeated AgentCardSignature signatures = 17;
456454
// An optional URL to an icon for the agent.
@@ -481,6 +479,8 @@ message AgentCapabilities {
481479
repeated AgentExtension extensions = 3;
482480
// Indicates if the agent provides a history of state transitions for a task.
483481
optional bool state_transition_history = 4;
482+
// Indicates if the agent supports providing an extended agent card when authenticated.
483+
optional bool extended_agent_card = 5;
484484
}
485485
// --8<-- [end:AgentCapabilities]
486486

0 commit comments

Comments
 (0)