44
55import java .util .UUID ;
66
7+ import io .a2a .spec .AgentCapabilities ;
78import io .a2a .spec .AgentCard ;
8- import io .a2a .spec .ExtendedCardNotConfiguredError ;
9+ import io .a2a .spec .ExtendedAgentCardNotConfiguredError ;
910
1011/**
1112 * JSON-RPC request to retrieve an agent's extended card with authenticated details.
2021 * </ul>
2122 * <p>
2223 * The agent must support authenticated extended cards (indicated by
23- * {@link AgentCard#supportsExtendedAgentCard() }) and the client must provide
24+ * {@link AgentCapabilities#extendedAgentCard()} }) and the client must provide
2425 * valid authentication credentials for this request to succeed.
2526 * <p>
26- * This class implements the JSON-RPC {@code agent/getAuthenticatedExtendedCard } method
27+ * This class implements the JSON-RPC {@code GetExtendedAgentCard } method
2728 * as specified in the A2A Protocol.
2829 *
29- * @see GetAuthenticatedExtendedCardResponse for the corresponding response
30+ * @see GetExtendedAgentCardResponse for the corresponding response
3031 * @see AgentCard for the card structure
31- * @see ExtendedCardNotConfiguredError for the error when unsupported
32+ * @see ExtendedAgentCardNotConfiguredError for the error when unsupported
3233 * @see <a href="https://a2a-protocol.org/latest/">A2A Protocol Specification</a>
3334 */
34- public final class GetAuthenticatedExtendedCardRequest extends NonStreamingJSONRPCRequest <Void > {
35+ public final class GetExtendedAgentCardRequest extends NonStreamingJSONRPCRequest <Void > {
3536
3637 /**
3738 * Constructs request with full parameters.
3839 *
3940 * @param jsonrpc the JSON-RPC version
4041 * @param id the request ID
4142 */
42- public GetAuthenticatedExtendedCardRequest (String jsonrpc , Object id ) {
43+ public GetExtendedAgentCardRequest (String jsonrpc , Object id ) {
4344 super (jsonrpc , GET_EXTENDED_AGENT_CARD_METHOD , id );
4445 }
4546
@@ -48,7 +49,7 @@ public GetAuthenticatedExtendedCardRequest(String jsonrpc, Object id) {
4849 *
4950 * @param id the request ID
5051 */
51- public GetAuthenticatedExtendedCardRequest (String id ) {
52+ public GetExtendedAgentCardRequest (String id ) {
5253 this (null , id );
5354 }
5455
@@ -80,7 +81,7 @@ private Builder() {
8081 * @param jsonrpc the JSON-RPC version
8182 * @return this builder for method chaining
8283 */
83- public GetAuthenticatedExtendedCardRequest .Builder jsonrpc (String jsonrpc ) {
84+ public GetExtendedAgentCardRequest .Builder jsonrpc (String jsonrpc ) {
8485 this .jsonrpc = jsonrpc ;
8586 return this ;
8687 }
@@ -91,7 +92,7 @@ public GetAuthenticatedExtendedCardRequest.Builder jsonrpc(String jsonrpc) {
9192 * @param id the request ID
9293 * @return this builder for method chaining
9394 */
94- public GetAuthenticatedExtendedCardRequest .Builder id (Object id ) {
95+ public GetExtendedAgentCardRequest .Builder id (Object id ) {
9596 this .id = id ;
9697 return this ;
9798 }
@@ -101,11 +102,11 @@ public GetAuthenticatedExtendedCardRequest.Builder id(Object id) {
101102 *
102103 * @return a new instance
103104 */
104- public GetAuthenticatedExtendedCardRequest build () {
105+ public GetExtendedAgentCardRequest build () {
105106 if (id == null ) {
106107 id = UUID .randomUUID ().toString ();
107108 }
108- return new GetAuthenticatedExtendedCardRequest (jsonrpc , id );
109+ return new GetExtendedAgentCardRequest (jsonrpc , id );
109110 }
110111 }
111112}
0 commit comments