1818 * <p>
1919 * This class is immutable and uses the Builder pattern for construction to handle the mix of
2020 * required and optional fields defined by the specification.
21+ * <p>
22+ * <b>Important:</b> The {@link #supportedInterfaces()} field specifies how clients can
23+ * communicate with the agent. Each entry combines a protocol binding (e.g., "JSONRPC",
24+ * "GRPC") with a URL endpoint. The first entry in the list is the preferred interface.
2125 *
2226 * @param name the human-readable name of the agent (required)
2327 * @param description a brief description of the agent's purpose and functionality (required)
3236 * @param securitySchemes map of security scheme names to their definitions (optional)
3337 * @param security list of security requirements for accessing the agent (optional)
3438 * @param iconUrl URL to an icon representing the agent (optional)
35- * @param supportedInterfaces ordered list of supported interfaces. First entry is preferred. (required)
39+ * @param supportedInterfaces ordered list of protocol+URL interface combinations; first entry is preferred (required)
3640 * @param protocolVersion the version of the A2A Protocol this agent implements (defaults to {@link #DEFAULT_PROTOCOL_VERSION})
3741 * @param signatures digital signatures verifying the authenticity of the agent card (optional)
42+ * @see AgentInterface
3843 * @see <a href="https://a2a-protocol.org/latest/">A2A Protocol Specification</a>
3944 */
4045public record AgentCard (
@@ -61,6 +66,22 @@ public record AgentCard(
6166 /**
6267 * Compact constructor that validates required fields and sets defaults.
6368 *
69+ * @param name the name parameter (see class-level JavaDoc)
70+ * @param description the description parameter (see class-level JavaDoc)
71+ * @param provider the provider parameter (see class-level JavaDoc)
72+ * @param version the version parameter (see class-level JavaDoc)
73+ * @param documentationUrl the documentationUrl parameter (see class-level JavaDoc)
74+ * @param capabilities the capabilities parameter (see class-level JavaDoc)
75+ * @param defaultInputModes the defaultInputModes parameter (see class-level JavaDoc)
76+ * @param defaultOutputModes the defaultOutputModes parameter (see class-level JavaDoc)
77+ * @param skills the skills parameter (see class-level JavaDoc)
78+ * @param supportsExtendedAgentCard the supportsExtendedAgentCard parameter (see class-level JavaDoc)
79+ * @param securitySchemes the securitySchemes parameter (see class-level JavaDoc)
80+ * @param security the security parameter (see class-level JavaDoc)
81+ * @param iconUrl the iconUrl parameter (see class-level JavaDoc)
82+ * @param supportedInterfaces the supportedInterfaces parameter (see class-level JavaDoc)
83+ * @param protocolVersion the protocolVersion parameter (see class-level JavaDoc)
84+ * @param signatures the signatures parameter (see class-level JavaDoc)
6485 * @throws IllegalArgumentException if any required field is null
6586 */
6687 public AgentCard {
@@ -78,17 +99,6 @@ public record AgentCard(
7899 }
79100 }
80101
81- /**
82- * Returns the list of additional interfaces.
83- *
84- * @return the list of supported interfaces
85- * @deprecated Use {@link #supportedInterfaces()} instead. This field has been renamed to 'supportedInterfaces'.
86- */
87- @ Deprecated (since = "0.4.0" , forRemoval = true )
88- public List <AgentInterface > additionalInterfaces () {
89- return supportedInterfaces ;
90- }
91-
92102 /**
93103 * Create a new Builder
94104 *
@@ -362,11 +372,21 @@ public Builder iconUrl(String iconUrl) {
362372 }
363373
364374 /**
365- * Sets the ordered list of supported interfaces (first entry is preferred).
375+ * Sets the ordered list of supported protocol interfaces (first entry is preferred).
376+ * <p>
377+ * Each interface defines a combination of protocol binding (e.g., "JSONRPC", "GRPC", "REST")
378+ * and URL endpoint for accessing the agent. This is the primary field for declaring how
379+ * clients can communicate with the agent as of protocol version 1.0.0.
366380 * <p>
367- * Each interface defines a combination of protocol binding and URL for accessing the agent.
381+ * Example:
382+ * <pre>{@code
383+ * .supportedInterfaces(List.of(
384+ * new AgentInterface("JSONRPC", "http://localhost:9999"),
385+ * new AgentInterface("GRPC", "grpc://localhost:9090")
386+ * ))
387+ * }</pre>
368388 *
369- * @param supportedInterfaces the ordered list of supported interfaces (optional )
389+ * @param supportedInterfaces the ordered list of supported interfaces (required )
370390 * @return this builder for method chaining
371391 * @see AgentInterface
372392 */
0 commit comments