diff --git a/client/base/src/main/java/io/a2a/client/AbstractClient.java b/client/base/src/main/java/io/a2a/client/AbstractClient.java index 75fe48956..5d2785386 100644 --- a/client/base/src/main/java/io/a2a/client/AbstractClient.java +++ b/client/base/src/main/java/io/a2a/client/AbstractClient.java @@ -384,23 +384,23 @@ public abstract void resubscribe(@NonNull TaskIdParams request, @Nullable ClientCallContext context) throws A2AClientException; /** - * Retrieve the AgentCard. + * Retrieve the extended AgentCard. * - * @return the AgentCard - * @throws A2AClientException if retrieving the agent card fails for any reason + * @return the extended AgentCard + * @throws A2AClientException if retrieving the extended agent card fails for any reason */ - public AgentCard getAgentCard() throws A2AClientException { - return getAgentCard(null); + public AgentCard getExtendedAgentCard() throws A2AClientException { + return getExtendedAgentCard(null); } /** - * Retrieve the AgentCard. + * Retrieve the extended AgentCard. * * @param context optional client call context for the request (may be {@code null}) - * @return the AgentCard - * @throws A2AClientException if retrieving the agent card fails for any reason + * @return the extended AgentCard + * @throws A2AClientException if retrieving the extended agent card fails for any reason */ - public abstract AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2AClientException; + public abstract AgentCard getExtendedAgentCard(@Nullable ClientCallContext context) throws A2AClientException; /** * Close the transport and release any associated resources. diff --git a/client/base/src/main/java/io/a2a/client/Client.java b/client/base/src/main/java/io/a2a/client/Client.java index 9976133e5..117351098 100644 --- a/client/base/src/main/java/io/a2a/client/Client.java +++ b/client/base/src/main/java/io/a2a/client/Client.java @@ -592,27 +592,28 @@ public void resubscribe(@NonNull TaskIdParams request, } /** - * Retrieve the agent's current agent card. + * Retrieve the agent's extended agent card. *

- * This method fetches the latest agent card from the agent. The card may have changed since + * This method fetches the extended agent card from the agent (if the extendedAgentCard capability is supported). + * The card may have changed since * client construction (e.g., new skills added, capabilities updated). The client's internal * reference is updated to the newly retrieved card. *

* Example: *

{@code
-     * AgentCard updatedCard = client.getAgentCard(null);
+     * AgentCard updatedCard = client.getExtendedAgentCard(null);
      * System.out.println("Agent version: " + updatedCard.version());
      * System.out.println("Skills: " + updatedCard.skills().size());
      * }
* * @param context custom call context for request interceptors (optional) - * @return the agent's current agent card - * @throws A2AClientException if the agent card cannot be retrieved + * @return the agent's extended agent card + * @throws A2AClientException if the extended agent card cannot be retrieved * @see AgentCard */ @Override - public AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2AClientException { - agentCard = clientTransport.getAgentCard(context); + public AgentCard getExtendedAgentCard(@Nullable ClientCallContext context) throws A2AClientException { + agentCard = clientTransport.getExtendedAgentCard(context); return agentCard; } diff --git a/client/base/src/test/java/io/a2a/client/AuthenticationAuthorizationTest.java b/client/base/src/test/java/io/a2a/client/AuthenticationAuthorizationTest.java index 0294b3dc4..58b528881 100644 --- a/client/base/src/test/java/io/a2a/client/AuthenticationAuthorizationTest.java +++ b/client/base/src/test/java/io/a2a/client/AuthenticationAuthorizationTest.java @@ -90,7 +90,7 @@ public void setUp() { .description("Test skill") .tags(Collections.singletonList("test")) .build())) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .supportedInterfaces(java.util.Arrays.asList( new AgentInterface(TransportProtocol.JSONRPC.asString(), AGENT_URL), new AgentInterface(TransportProtocol.HTTP_JSON.asString(), AGENT_URL), diff --git a/client/base/src/test/java/io/a2a/client/ClientBuilderTest.java b/client/base/src/test/java/io/a2a/client/ClientBuilderTest.java index 2c95c2619..56eb7560d 100644 --- a/client/base/src/test/java/io/a2a/client/ClientBuilderTest.java +++ b/client/base/src/test/java/io/a2a/client/ClientBuilderTest.java @@ -42,7 +42,7 @@ public class ClientBuilderTest { .tags(Collections.singletonList("hello world")) .examples(List.of("hi", "hello world")) .build())) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .supportedInterfaces(List.of( new AgentInterface(TransportProtocol.JSONRPC.asString(), "http://localhost:9999"))) .build(); diff --git a/client/transport/grpc/src/main/java/io/a2a/client/transport/grpc/EventStreamObserver.java b/client/transport/grpc/src/main/java/io/a2a/client/transport/grpc/EventStreamObserver.java index d77b81824..0c928bd75 100644 --- a/client/transport/grpc/src/main/java/io/a2a/client/transport/grpc/EventStreamObserver.java +++ b/client/transport/grpc/src/main/java/io/a2a/client/transport/grpc/EventStreamObserver.java @@ -25,8 +25,8 @@ public EventStreamObserver(Consumer eventHandler, Consumer interceptors; - private AgentCard agentCard; + private final AgentCard agentCard; private final String agentTenant; public GrpcTransport(Channel channel, AgentCard agentCard) { @@ -104,8 +106,8 @@ public EventKind sendMessage(MessageSendParams request, @Nullable ClientCallCont try { A2AServiceBlockingV2Stub stubWithMetadata = createBlockingStubWithMetadata(context, payloadAndHeaders); io.a2a.grpc.SendMessageResponse response = stubWithMetadata.sendMessage(sendMessageRequest); - if (response.hasMsg()) { - return FromProto.message(response.getMsg()); + if (response.hasMessage()) { + return FromProto.message(response.getMessage()); } else if (response.hasTask()) { return FromProto.task(response.getTask()); } else { @@ -195,8 +197,12 @@ public ListTasksResult listTasks(ListTasksParams request, @Nullable ClientCallCo if (request.historyLength() != null) { requestBuilder.setHistoryLength(request.historyLength()); } - if (request.lastUpdatedAfter() != null) { - requestBuilder.setLastUpdatedAfter(request.lastUpdatedAfter().toEpochMilli()); + if (request.statusTimestampAfter() != null) { + requestBuilder.setStatusTimestampAfter( + com.google.protobuf.Timestamp.newBuilder() + .setSeconds(request.statusTimestampAfter().getEpochSecond()) + .setNanos(request.statusTimestampAfter().getNano()) + .build()); } if (request.includeArtifacts() != null) { requestBuilder.setIncludeArtifacts(request.includeArtifacts()); @@ -344,9 +350,19 @@ private MessageSendParams createRequestWithTenant(MessageSendParams request) { } @Override - public AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2AClientException { - // TODO: Determine how to handle retrieving the authenticated extended agent card - return agentCard; + public AgentCard getExtendedAgentCard(@Nullable ClientCallContext context) throws A2AClientException { + GetExtendedAgentCardRequest request = GetExtendedAgentCardRequest.newBuilder() + .build(); + PayloadAndHeaders payloadAndHeaders = applyInterceptors(GET_EXTENDED_AGENT_CARD_METHOD, request, agentCard, context); + + try { + A2AServiceBlockingV2Stub stubWithMetadata = createBlockingStubWithMetadata(context, payloadAndHeaders); + io.a2a.grpc.AgentCard response = stubWithMetadata.getExtendedAgentCard(request); + + return FromProto.agentCard(response); + } catch (StatusRuntimeException | StatusException e) { + throw GrpcErrorMapper.mapGrpcError(e, "Failed to get extended agent card: "); + } } @Override diff --git a/client/transport/grpc/src/test/java/io/a2a/client/transport/grpc/GrpcErrorMapperTest.java b/client/transport/grpc/src/test/java/io/a2a/client/transport/grpc/GrpcErrorMapperTest.java index b68f7c958..864e406d2 100644 --- a/client/transport/grpc/src/test/java/io/a2a/client/transport/grpc/GrpcErrorMapperTest.java +++ b/client/transport/grpc/src/test/java/io/a2a/client/transport/grpc/GrpcErrorMapperTest.java @@ -7,15 +7,9 @@ import io.a2a.spec.A2AClientException; import io.a2a.spec.ContentTypeNotSupportedError; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.ExtensionSupportRequiredError; -import io.a2a.spec.InvalidAgentResponseError; import io.a2a.spec.InvalidParamsError; -import io.a2a.spec.InvalidRequestError; -import io.a2a.spec.JSONParseError; -import io.a2a.spec.MethodNotFoundError; -import io.a2a.spec.PushNotificationNotSupportedError; -import io.a2a.spec.TaskNotCancelableError; import io.a2a.spec.TaskNotFoundError; import io.a2a.spec.UnsupportedOperationError; import io.a2a.spec.VersionNotSupportedError; @@ -85,9 +79,9 @@ public void testExtendedCardNotConfiguredErrorUnmarshalling() { // Verify the result assertNotNull(result); assertNotNull(result.getCause()); - assertInstanceOf(ExtendedCardNotConfiguredError.class, result.getCause()); + assertInstanceOf(ExtendedAgentCardNotConfiguredError.class, result.getCause()); - ExtendedCardNotConfiguredError extendedCardError = (ExtendedCardNotConfiguredError) result.getCause(); + ExtendedAgentCardNotConfiguredError extendedCardError = (ExtendedAgentCardNotConfiguredError) result.getCause(); assertNotNull(extendedCardError.getMessage()); assertTrue(extendedCardError.getMessage().contains("Extended card not configured")); } diff --git a/client/transport/jsonrpc/src/main/java/io/a2a/client/transport/jsonrpc/JSONRPCTransport.java b/client/transport/jsonrpc/src/main/java/io/a2a/client/transport/jsonrpc/JSONRPCTransport.java index 8c948c4a8..e991eecb3 100644 --- a/client/transport/jsonrpc/src/main/java/io/a2a/client/transport/jsonrpc/JSONRPCTransport.java +++ b/client/transport/jsonrpc/src/main/java/io/a2a/client/transport/jsonrpc/JSONRPCTransport.java @@ -21,7 +21,7 @@ import java.util.function.Consumer; import com.google.protobuf.MessageOrBuilder; -import io.a2a.client.http.A2ACardResolver; + import io.a2a.client.http.A2AHttpClient; import io.a2a.client.http.A2AHttpClientFactory; import io.a2a.client.http.A2AHttpResponse; @@ -33,12 +33,10 @@ import io.a2a.grpc.utils.JSONRPCUtils; import io.a2a.grpc.utils.ProtoUtils; import io.a2a.jsonrpc.common.json.JsonProcessingException; -import io.a2a.jsonrpc.common.wrappers.A2AMessage; import io.a2a.jsonrpc.common.wrappers.A2AResponse; import io.a2a.jsonrpc.common.wrappers.CancelTaskResponse; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigResponse; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardRequest; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardResponse; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskResponse; import io.a2a.jsonrpc.common.wrappers.ListTaskPushNotificationConfigResponse; @@ -71,8 +69,7 @@ public class JSONRPCTransport implements ClientTransport { private final A2AHttpClient httpClient; private final AgentInterface agentInterface; private final @Nullable List interceptors; - private @Nullable AgentCard agentCard; - private boolean needsExtendedCard = false; + private final @Nullable AgentCard agentCard; public JSONRPCTransport(String agentUrl) { this(null, null, new AgentInterface("JSONRPC", agentUrl), null); @@ -88,7 +85,6 @@ public JSONRPCTransport(@Nullable A2AHttpClient httpClient, @Nullable AgentCard this.agentCard = agentCard; this.agentInterface = agentInterface; this.interceptors = interceptors; - this.needsExtendedCard = agentCard == null || agentCard.supportsExtendedAgentCard(); } @Override @@ -288,31 +284,15 @@ public void resubscribe(TaskIdParams request, Consumer event } @Override - public AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2AClientException { - A2ACardResolver resolver; + public AgentCard getExtendedAgentCard(@Nullable ClientCallContext context) throws A2AClientException { try { - if (agentCard == null) { - resolver = new A2ACardResolver(httpClient, agentInterface.url(), agentInterface.tenant(), null, getHttpHeaders(context)); - agentCard = resolver.getAgentCard(); - needsExtendedCard = agentCard.supportsExtendedAgentCard(); - } - if (!needsExtendedCard) { - return agentCard; - } - - GetAuthenticatedExtendedCardRequest getExtendedAgentCardRequest = GetAuthenticatedExtendedCardRequest.builder() - .jsonrpc(A2AMessage.JSONRPC_VERSION) - .build(); // id will be randomly generated - PayloadAndHeaders payloadAndHeaders = applyInterceptors(GET_EXTENDED_AGENT_CARD_METHOD, ProtoUtils.ToProto.extendedAgentCard(), agentCard, context); try { String httpResponseBody = sendPostRequest(Utils.buildBaseUrl(agentInterface, ""), payloadAndHeaders, GET_EXTENDED_AGENT_CARD_METHOD); - GetAuthenticatedExtendedCardResponse response = unmarshalResponse(httpResponseBody, GET_EXTENDED_AGENT_CARD_METHOD); - agentCard = response.getResult(); - needsExtendedCard = false; - return agentCard; + GetExtendedAgentCardResponse response = unmarshalResponse(httpResponseBody, GET_EXTENDED_AGENT_CARD_METHOD); + return response.getResult(); } catch (IOException | InterruptedException | JsonProcessingException e) { throw new A2AClientException("Failed to get authenticated extended agent card: " + e, e); } diff --git a/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JSONRPCTransportTest.java b/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JSONRPCTransportTest.java index 3344420a0..9b6f7f017 100644 --- a/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JSONRPCTransportTest.java +++ b/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JSONRPCTransportTest.java @@ -353,96 +353,8 @@ public void testA2AClientSetTaskPushNotificationConfig() throws Exception { assertEquals("jwt", authenticationInfo.schemes().get(0)); } - @Test - public void testA2AClientGetAgentCard() throws Exception { - this.server.when( - request() - .withMethod("GET") - .withPath("/.well-known/agent-card.json") - ) - .respond( - response() - .withStatusCode(200) - .withBody(AGENT_CARD) - ); - - JSONRPCTransport client = new JSONRPCTransport("http://localhost:4001"); - AgentCard agentCard = client.getAgentCard(null); - assertEquals("GeoSpatial Route Planner Agent", agentCard.name()); - assertEquals("Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.", agentCard.description()); - assertEquals("https://georoute-agent.example.com/a2a/v1", Utils.getFavoriteInterface(agentCard).url()); - assertEquals("Example Geo Services Inc.", agentCard.provider().organization()); - assertEquals("https://www.examplegeoservices.com", agentCard.provider().url()); - assertEquals("1.2.0", agentCard.version()); - assertEquals("https://docs.examplegeoservices.com/georoute-agent/api", agentCard.documentationUrl()); - assertTrue(agentCard.capabilities().streaming()); - assertTrue(agentCard.capabilities().pushNotifications()); - assertFalse(agentCard.capabilities().stateTransitionHistory()); - Map securitySchemes = agentCard.securitySchemes(); - assertNotNull(securitySchemes); - OpenIdConnectSecurityScheme google = (OpenIdConnectSecurityScheme) securitySchemes.get("google"); - assertEquals("https://accounts.google.com/.well-known/openid-configuration", google.openIdConnectUrl()); - List>> security = agentCard.security(); - assertEquals(1, security.size()); - Map> securityMap = security.get(0); - List scopes = securityMap.get("google"); - List expectedScopes = List.of("openid", "profile", "email"); - assertEquals(expectedScopes, scopes); - List defaultInputModes = List.of("application/json", "text/plain"); - assertEquals(defaultInputModes, agentCard.defaultInputModes()); - List defaultOutputModes = List.of("application/json", "image/png"); - assertEquals(defaultOutputModes, agentCard.defaultOutputModes()); - List skills = agentCard.skills(); - assertEquals("route-optimizer-traffic", skills.get(0).id()); - assertEquals("Traffic-Aware Route Optimizer", skills.get(0).name()); - assertEquals("Calculates the optimal driving route between two or more locations, taking into account real-time traffic conditions, road closures, and user preferences (e.g., avoid tolls, prefer highways).", skills.get(0).description()); - List tags = List.of("maps", "routing", "navigation", "directions", "traffic"); - assertEquals(tags, skills.get(0).tags()); - List examples = List.of("Plan a route from '1600 Amphitheatre Parkway, Mountain View, CA' to 'San Francisco International Airport' avoiding tolls.", - "{\"origin\": {\"lat\": 37.422, \"lng\": -122.084}, \"destination\": {\"lat\": 37.7749, \"lng\": -122.4194}, \"preferences\": [\"avoid_ferries\"]}"); - assertEquals(examples, skills.get(0).examples()); - assertEquals(defaultInputModes, skills.get(0).inputModes()); - List outputModes = List.of("application/json", "application/vnd.geo+json", "text/html"); - assertEquals(outputModes, skills.get(0).outputModes()); - assertEquals("custom-map-generator", skills.get(1).id()); - assertEquals("Personalized Map Generator", skills.get(1).name()); - assertEquals("Creates custom map images or interactive map views based on user-defined points of interest, routes, and style preferences. Can overlay data layers.", skills.get(1).description()); - tags = List.of("maps", "customization", "visualization", "cartography"); - assertEquals(tags, skills.get(1).tags()); - examples = List.of("Generate a map of my upcoming road trip with all planned stops highlighted.", - "Show me a map visualizing all coffee shops within a 1-mile radius of my current location."); - assertEquals(examples, skills.get(1).examples()); - List inputModes = List.of("application/json"); - assertEquals(inputModes, skills.get(1).inputModes()); - outputModes = List.of("image/png", "image/jpeg", "application/json", "text/html"); - assertEquals(outputModes, skills.get(1).outputModes()); - assertFalse(agentCard.supportsExtendedAgentCard()); - assertEquals("https://georoute-agent.example.com/icon.png", agentCard.iconUrl()); - assertEquals(CURRENT_PROTOCOL_VERSION, agentCard.protocolVersion()); - assertEquals("JSONRPC", agentCard.supportedInterfaces().get(0).protocolBinding()); - List additionalInterfaces = agentCard.supportedInterfaces(); - assertEquals(3, additionalInterfaces.size()); - AgentInterface jsonrpc = new AgentInterface(TransportProtocol.JSONRPC.asString(), "https://georoute-agent.example.com/a2a/v1"); - AgentInterface grpc = new AgentInterface(TransportProtocol.GRPC.asString(), "https://georoute-agent.example.com/a2a/grpc"); - AgentInterface httpJson = new AgentInterface(TransportProtocol.HTTP_JSON.asString(), "https://georoute-agent.example.com/a2a/json"); - assertEquals(jsonrpc, additionalInterfaces.get(0)); - assertEquals(grpc, additionalInterfaces.get(1)); - assertEquals(httpJson, additionalInterfaces.get(2)); - } - - @Test - public void testA2AClientGetAuthenticatedExtendedAgentCard() throws Exception { - this.server.when( - request() - .withMethod("GET") - .withPath("/.well-known/agent-card.json") - ) - .respond( - response() - .withStatusCode(200) - .withBody(AGENT_CARD_SUPPORTS_EXTENDED) - ); + public void testA2AClientGetExtendedAgentCard() throws Exception { this.server.when( request() .withMethod("POST") @@ -456,7 +368,7 @@ public void testA2AClientGetAuthenticatedExtendedAgentCard() throws Exception { ); JSONRPCTransport client = new JSONRPCTransport("http://localhost:4001"); - AgentCard agentCard = client.getAgentCard(null); + AgentCard agentCard = client.getExtendedAgentCard(null); assertEquals("GeoSpatial Route Planner Agent Extended", agentCard.name()); assertEquals("Extended description", agentCard.description()); assertEquals("https://georoute-agent.example.com/a2a/v1", Utils.getFavoriteInterface(agentCard).url()); @@ -467,6 +379,7 @@ public void testA2AClientGetAuthenticatedExtendedAgentCard() throws Exception { assertTrue(agentCard.capabilities().streaming()); assertTrue(agentCard.capabilities().pushNotifications()); assertFalse(agentCard.capabilities().stateTransitionHistory()); + assertTrue(agentCard.capabilities().extendedAgentCard()); Map securitySchemes = agentCard.securitySchemes(); assertNotNull(securitySchemes); OpenIdConnectSecurityScheme google = (OpenIdConnectSecurityScheme) securitySchemes.get("google"); @@ -509,9 +422,8 @@ public void testA2AClientGetAuthenticatedExtendedAgentCard() throws Exception { assertEquals("Extended Skill", skills.get(2).name()); assertEquals("This is an extended skill.", skills.get(2).description()); assertEquals(List.of("extended"), skills.get(2).tags()); - assertTrue(agentCard.supportsExtendedAgentCard()); assertEquals("https://georoute-agent.example.com/icon.png", agentCard.iconUrl()); - assertEquals(CURRENT_PROTOCOL_VERSION, agentCard.protocolVersion()); + assertEquals(CURRENT_PROTOCOL_VERSION, agentCard.protocolVersions().get(0)); } @Test diff --git a/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JsonMessages.java b/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JsonMessages.java index 27c27a7ab..dfdbb9741 100644 --- a/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JsonMessages.java +++ b/client/transport/jsonrpc/src/test/java/io/a2a/client/transport/jsonrpc/JsonMessages.java @@ -10,7 +10,7 @@ public class JsonMessages { static final String AGENT_CARD = String.format(""" { - "protocolVersion": "%s", + "protocolVersions": ["%s"], "name": "GeoSpatial Route Planner Agent", "description": "Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.", "supportedInterfaces" : [ @@ -28,7 +28,8 @@ public class JsonMessages { "capabilities": { "streaming": true, "pushNotifications": true, - "stateTransitionHistory": false + "stateTransitionHistory": false, + "extendedAgentCard": false }, "securitySchemes": { "google": { @@ -75,7 +76,6 @@ public class JsonMessages { ] } ], - "supportsExtendedAgentCard": false, "signatures": [ { "protected": "eyJhbGciOiJFUzI1NiIsInR5cCI6IkpPU0UiLCJraWQiOiJrZXktMSIsImprdSI6Imh0dHBzOi8vZXhhbXBsZS5jb20vYWdlbnQvandrcy5qc29uIn0", @@ -610,7 +610,8 @@ public class JsonMessages { "capabilities": { "streaming": true, "pushNotifications": true, - "stateTransitionHistory": false + "stateTransitionHistory": false, + "extendedAgentCard": true }, "securitySchemes": { "google": { @@ -663,8 +664,7 @@ public class JsonMessages { "tags": ["extended"] } ], - "supportsExtendedAgentCard": true, - "protocolVersion": "%s", + "protocolVersions": ["%s"], "signatures": [ { "protected": "eyJhbGciOiJFUzI1NiIsInR5cCI6IkpPU0UiLCJraWQiOiJrZXktMSIsImprdUI6Imh0dHBzOi8vZXhhbXBsZS5jb20vYWdlbnQvandrcy5qc29uIn0", @@ -691,7 +691,8 @@ public class JsonMessages { "capabilities": { "streaming": true, "pushNotifications": true, - "stateTransitionHistory": false + "stateTransitionHistory": false, + "extendedAgentCard": true }, "securitySchemes": { "google": { @@ -738,7 +739,6 @@ public class JsonMessages { ] } ], - "supportsExtendedAgentCard": true, - "protocolVersion": "%s" + "protocolVersions": ["%s"] }""", CURRENT_PROTOCOL_VERSION); } diff --git a/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestErrorMapper.java b/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestErrorMapper.java index 76e6df404..92ce45416 100644 --- a/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestErrorMapper.java +++ b/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestErrorMapper.java @@ -8,7 +8,7 @@ import io.a2a.jsonrpc.common.json.JsonProcessingException; import io.a2a.jsonrpc.common.json.JsonUtil; import io.a2a.spec.A2AClientException; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.ContentTypeNotSupportedError; import io.a2a.spec.ExtensionSupportRequiredError; import io.a2a.spec.InternalError; @@ -50,8 +50,7 @@ public static A2AClientException mapRestError(String body, int code) { public static A2AClientException mapRestError(String className, String errorMessage, int code) { return switch (className) { case "io.a2a.spec.TaskNotFoundError" -> new A2AClientException(errorMessage, new TaskNotFoundError()); - case "io.a2a.spec.AuthenticatedExtendedCardNotConfiguredError", - "io.a2a.spec.ExtendedCardNotConfiguredError" -> new A2AClientException(errorMessage, new ExtendedCardNotConfiguredError(null, errorMessage, null)); + case "io.a2a.spec.ExtendedCardNotConfiguredError" -> new A2AClientException(errorMessage, new ExtendedAgentCardNotConfiguredError(null, errorMessage, null)); case "io.a2a.spec.ContentTypeNotSupportedError" -> new A2AClientException(errorMessage, new ContentTypeNotSupportedError(null, null, errorMessage)); case "io.a2a.spec.InternalError" -> new A2AClientException(errorMessage, new InternalError(errorMessage)); case "io.a2a.spec.InvalidAgentResponseError" -> new A2AClientException(errorMessage, new InvalidAgentResponseError(null, null, errorMessage)); diff --git a/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestTransport.java b/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestTransport.java index d67972a07..6513086da 100644 --- a/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestTransport.java +++ b/client/transport/rest/src/main/java/io/a2a/client/transport/rest/RestTransport.java @@ -65,8 +65,7 @@ public class RestTransport implements ClientTransport { private final A2AHttpClient httpClient; private final AgentInterface agentInterface; private @Nullable final List interceptors; - private AgentCard agentCard; - private boolean needsExtendedCard = false; + private final AgentCard agentCard; public RestTransport(AgentCard agentCard) { this(null, agentCard, Utils.getFavoriteInterface(agentCard), null); @@ -89,8 +88,8 @@ public EventKind sendMessage(MessageSendParams messageSendParams, @Nullable Clie String httpResponseBody = sendPostRequest(Utils.buildBaseUrl(agentInterface, messageSendParams.tenant()) + "/message:send", payloadAndHeaders); io.a2a.grpc.SendMessageResponse.Builder responseBuilder = io.a2a.grpc.SendMessageResponse.newBuilder(); JsonFormat.parser().merge(httpResponseBody, responseBuilder); - if (responseBuilder.hasMsg()) { - return ProtoUtils.FromProto.message(responseBuilder.getMsg()); + if (responseBuilder.hasMessage()) { + return ProtoUtils.FromProto.message(responseBuilder.getMessage()); } if (responseBuilder.hasTask()) { return ProtoUtils.FromProto.task(responseBuilder.getTask()); @@ -416,17 +415,8 @@ public void resubscribe(TaskIdParams request, Consumer event } @Override - public AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2AClientException { - A2ACardResolver resolver; + public AgentCard getExtendedAgentCard(@Nullable ClientCallContext context) throws A2AClientException { try { - if (agentCard == null) { - resolver = new A2ACardResolver(httpClient, agentInterface.url(), agentInterface.tenant(), null, getHttpHeaders(context)); - agentCard = resolver.getAgentCard(); - needsExtendedCard = agentCard.supportsExtendedAgentCard(); - } - if (!needsExtendedCard) { - return agentCard; - } PayloadAndHeaders payloadAndHeaders = applyInterceptors(GET_EXTENDED_AGENT_CARD_METHOD, null, agentCard, context); String url = Utils.buildBaseUrl(agentInterface, "") + "/extendedAgentCard"; A2AHttpClient.GetBuilder getBuilder = httpClient.createGet().url(url); @@ -440,9 +430,7 @@ public AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2ACli throw RestErrorMapper.mapRestError(response); } String httpResponseBody = response.body(); - agentCard = JsonUtil.fromJson(httpResponseBody, AgentCard.class); - needsExtendedCard = false; - return agentCard; + return JsonUtil.fromJson(httpResponseBody, AgentCard.class); } catch (IOException | InterruptedException | JsonProcessingException e) { throw new A2AClientException("Failed to get authenticated extended agent card: " + e, e); } catch (A2AClientError e) { diff --git a/client/transport/rest/src/main/java/io/a2a/client/transport/rest/sse/RestSSEEventListener.java b/client/transport/rest/src/main/java/io/a2a/client/transport/rest/sse/RestSSEEventListener.java index 58a1a57f0..ec74d2fbc 100644 --- a/client/transport/rest/src/main/java/io/a2a/client/transport/rest/sse/RestSSEEventListener.java +++ b/client/transport/rest/src/main/java/io/a2a/client/transport/rest/sse/RestSSEEventListener.java @@ -47,8 +47,8 @@ public void onError(Throwable throwable, @Nullable Future future) { private void handleMessage(StreamResponse response) { StreamingEventKind event; switch (response.getPayloadCase()) { - case MSG -> - event = ProtoUtils.FromProto.message(response.getMsg()); + case MESSAGE -> + event = ProtoUtils.FromProto.message(response.getMessage()); case TASK -> event = ProtoUtils.FromProto.task(response.getTask()); case STATUS_UPDATE -> diff --git a/client/transport/rest/src/test/java/io/a2a/client/transport/rest/RestTransportTest.java b/client/transport/rest/src/test/java/io/a2a/client/transport/rest/RestTransportTest.java index eda760130..879363d9c 100644 --- a/client/transport/rest/src/test/java/io/a2a/client/transport/rest/RestTransportTest.java +++ b/client/transport/rest/src/test/java/io/a2a/client/transport/rest/RestTransportTest.java @@ -91,7 +91,7 @@ public class RestTransportTest { .tags(Collections.singletonList("hello world")) .examples(List.of("hi", "hello world")) .build())) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); @BeforeEach diff --git a/client/transport/spi/src/main/java/io/a2a/client/transport/spi/ClientTransport.java b/client/transport/spi/src/main/java/io/a2a/client/transport/spi/ClientTransport.java index e0f4b3a0c..df95e9ffd 100644 --- a/client/transport/spi/src/main/java/io/a2a/client/transport/spi/ClientTransport.java +++ b/client/transport/spi/src/main/java/io/a2a/client/transport/spi/ClientTransport.java @@ -137,13 +137,13 @@ void resubscribe(TaskIdParams request, Consumer eventConsume Consumer errorConsumer, @Nullable ClientCallContext context) throws A2AClientException; /** - * Retrieve the AgentCard. + * Retrieve the extended AgentCard. * * @param context optional client call context for the request (may be {@code null}) - * @return the AgentCard + * @return the extended agent card * @throws A2AClientException if retrieving the agent card fails for any reason */ - AgentCard getAgentCard(@Nullable ClientCallContext context) throws A2AClientException; + AgentCard getExtendedAgentCard(@Nullable ClientCallContext context) throws A2AClientException; /** * Close the transport and release any associated resources. diff --git a/examples/cloud-deployment/server/src/main/java/io/a2a/examples/cloud/CloudAgentCardProducer.java b/examples/cloud-deployment/server/src/main/java/io/a2a/examples/cloud/CloudAgentCardProducer.java index 07c7aea04..39e968ccf 100644 --- a/examples/cloud-deployment/server/src/main/java/io/a2a/examples/cloud/CloudAgentCardProducer.java +++ b/examples/cloud-deployment/server/src/main/java/io/a2a/examples/cloud/CloudAgentCardProducer.java @@ -58,7 +58,7 @@ public AgentCard agentCard() { )) .build() )) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); } } diff --git a/examples/cloud-deployment/server/src/test/java/io/a2a/examples/cloud/A2ACloudExampleClient.java b/examples/cloud-deployment/server/src/test/java/io/a2a/examples/cloud/A2ACloudExampleClient.java index 73d080c45..b29b0b55f 100644 --- a/examples/cloud-deployment/server/src/test/java/io/a2a/examples/cloud/A2ACloudExampleClient.java +++ b/examples/cloud-deployment/server/src/test/java/io/a2a/examples/cloud/A2ACloudExampleClient.java @@ -68,6 +68,8 @@ public class A2ACloudExampleClient { private Client nonStreamingClient; private ClientConfig nonStreamingConfig; + private AgentCard agentCard; + public static void main(String[] args) throws Exception { new A2ACloudExampleClient().run(); } @@ -75,7 +77,7 @@ public static void main(String[] args) throws Exception { private void run() throws Exception { printHeader(); - AgentCard agentCard = fetchAndConfigureAgentCard(); + agentCard = fetchAndConfigureAgentCard(); String clientTaskId = generateClientTaskId(); createClients(agentCard); @@ -273,7 +275,7 @@ private void sendProcessMessages() throws InterruptedException { final int messageNum = messageCount; // Create a new client for each request to force new HTTP connection - Client freshClient = Client.builder(streamingClient.getAgentCard()) + Client freshClient = Client.builder(agentCard) .clientConfig(nonStreamingConfig) .withTransport(JSONRPCTransport.class, new JSONRPCTransportConfigBuilder()) .build(); @@ -318,7 +320,7 @@ private void sendCompleteMessage() { System.out.println(); System.out.println("Step 4: Sending 'complete' to finalize task..."); - Client completeClient = Client.builder(streamingClient.getAgentCard()) + Client completeClient = Client.builder(agentCard) .clientConfig(nonStreamingConfig) .withTransport(JSONRPCTransport.class, new JSONRPCTransportConfigBuilder()) .build(); diff --git a/examples/helloworld/client/src/main/java/io/a2a/examples/helloworld/HelloWorldClient.java b/examples/helloworld/client/src/main/java/io/a2a/examples/helloworld/HelloWorldClient.java index c3b1cb473..5b8a6d196 100644 --- a/examples/helloworld/client/src/main/java/io/a2a/examples/helloworld/HelloWorldClient.java +++ b/examples/helloworld/client/src/main/java/io/a2a/examples/helloworld/HelloWorldClient.java @@ -40,11 +40,11 @@ public static void main(String[] args) { System.out.println("Using public agent card for client initialization (default)."); finalAgentCard = publicAgentCard; - if (publicAgentCard.supportsExtendedAgentCard()) { - System.out.println("Public card supports authenticated extended card. Attempting to fetch from: " + SERVER_URL + "/agent/authenticatedExtendedCard"); + if (publicAgentCard.capabilities().extendedAgentCard()) { + System.out.println("Public card supports authenticated extended card. Attempting to fetch from: " + SERVER_URL + "/ExtendedAgentCard"); Map authHeaders = new HashMap<>(); authHeaders.put("Authorization", "Bearer dummy-token-for-extended-card"); - AgentCard extendedAgentCard = A2A.getAgentCard(SERVER_URL, "/agent/authenticatedExtendedCard", authHeaders); + AgentCard extendedAgentCard = A2A.getAgentCard(SERVER_URL, "/ExtendedAgentCard", authHeaders); System.out.println("Successfully fetched authenticated extended agent card:"); System.out.println(JsonUtil.toJson(extendedAgentCard)); System.out.println("Using AUTHENTICATED EXTENDED agent card for client initialization."); diff --git a/examples/helloworld/server/src/main/java/io/a2a/examples/helloworld/AgentCardProducer.java b/examples/helloworld/server/src/main/java/io/a2a/examples/helloworld/AgentCardProducer.java index 66f1c7fc4..42f631924 100644 --- a/examples/helloworld/server/src/main/java/io/a2a/examples/helloworld/AgentCardProducer.java +++ b/examples/helloworld/server/src/main/java/io/a2a/examples/helloworld/AgentCardProducer.java @@ -43,7 +43,7 @@ public AgentCard agentCard() { .tags(Collections.singletonList("hello world")) .examples(List.of("hi", "hello world")) .build())) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); } } diff --git a/extras/queue-manager-replicated/tests-multi-instance/quarkus-common/src/main/java/io/a2a/extras/queuemanager/replicated/tests/multiinstance/common/MultiInstanceReplicationAgentCards.java b/extras/queue-manager-replicated/tests-multi-instance/quarkus-common/src/main/java/io/a2a/extras/queuemanager/replicated/tests/multiinstance/common/MultiInstanceReplicationAgentCards.java index 9936ea4df..f029fd120 100644 --- a/extras/queue-manager-replicated/tests-multi-instance/quarkus-common/src/main/java/io/a2a/extras/queuemanager/replicated/tests/multiinstance/common/MultiInstanceReplicationAgentCards.java +++ b/extras/queue-manager-replicated/tests-multi-instance/quarkus-common/src/main/java/io/a2a/extras/queuemanager/replicated/tests/multiinstance/common/MultiInstanceReplicationAgentCards.java @@ -48,7 +48,7 @@ public static AgentCard createAgentCard(int instanceNumber, int port) { .description("Fire-and-forget agent for testing replication") .tags(Collections.singletonList("test")) .build())) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); } } diff --git a/extras/queue-manager-replicated/tests-single-instance/src/test/java/io/a2a/extras/queuemanager/replicated/tests/ReplicationTestAgentCardProducer.java b/extras/queue-manager-replicated/tests-single-instance/src/test/java/io/a2a/extras/queuemanager/replicated/tests/ReplicationTestAgentCardProducer.java index 7a0e9280e..b476fc497 100644 --- a/extras/queue-manager-replicated/tests-single-instance/src/test/java/io/a2a/extras/queuemanager/replicated/tests/ReplicationTestAgentCardProducer.java +++ b/extras/queue-manager-replicated/tests-single-instance/src/test/java/io/a2a/extras/queuemanager/replicated/tests/ReplicationTestAgentCardProducer.java @@ -39,7 +39,7 @@ public AgentCard agentCard() { .skills(List.of()) .supportedInterfaces(List.of( new AgentInterface(TransportProtocol.JSONRPC.asString(), "http://localhost:8081"))) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); } } \ No newline at end of file diff --git a/extras/task-store-database-jpa/src/main/java/io/a2a/extras/taskstore/database/jpa/JpaDatabaseTaskStore.java b/extras/task-store-database-jpa/src/main/java/io/a2a/extras/taskstore/database/jpa/JpaDatabaseTaskStore.java index 840773ea6..0db0e1548 100644 --- a/extras/task-store-database-jpa/src/main/java/io/a2a/extras/taskstore/database/jpa/JpaDatabaseTaskStore.java +++ b/extras/task-store-database-jpa/src/main/java/io/a2a/extras/taskstore/database/jpa/JpaDatabaseTaskStore.java @@ -261,10 +261,10 @@ public ListTasksResult list(ListTasksParams params) { countQueryBuilder.append(" AND t.state = :state"); } - // Apply lastUpdatedAfter filter using denormalized timestamp column - if (params.lastUpdatedAfter() != null) { - queryBuilder.append(" AND t.statusTimestamp > :lastUpdatedAfter"); - countQueryBuilder.append(" AND t.statusTimestamp > :lastUpdatedAfter"); + // Apply statusTimestampAfter filter using denormalized timestamp column + if (params.statusTimestampAfter() != null) { + queryBuilder.append(" AND t.statusTimestamp > :statusTimestampAfter"); + countQueryBuilder.append(" AND t.statusTimestamp > :statusTimestampAfter"); } // Apply pagination cursor using keyset pagination for composite sort (timestamp DESC, id ASC) @@ -286,8 +286,8 @@ public ListTasksResult list(ListTasksParams params) { if (params.status() != null) { query.setParameter("state", params.status().asString()); } - if (params.lastUpdatedAfter() != null) { - query.setParameter("lastUpdatedAfter", params.lastUpdatedAfter()); + if (params.statusTimestampAfter() != null) { + query.setParameter("statusTimestampAfter", params.statusTimestampAfter()); } if (tokenTimestamp != null) { query.setParameter("tokenTimestamp", tokenTimestamp); @@ -315,8 +315,8 @@ public ListTasksResult list(ListTasksParams params) { if (params.status() != null) { countQuery.setParameter("state", params.status().asString()); } - if (params.lastUpdatedAfter() != null) { - countQuery.setParameter("lastUpdatedAfter", params.lastUpdatedAfter()); + if (params.statusTimestampAfter() != null) { + countQuery.setParameter("statusTimestampAfter", params.statusTimestampAfter()); } int totalSize = countQuery.getSingleResult().intValue(); diff --git a/http-client/src/test/java/io/a2a/client/http/JsonMessages.java b/http-client/src/test/java/io/a2a/client/http/JsonMessages.java index d889b8e2c..794017432 100644 --- a/http-client/src/test/java/io/a2a/client/http/JsonMessages.java +++ b/http-client/src/test/java/io/a2a/client/http/JsonMessages.java @@ -8,7 +8,7 @@ public class JsonMessages { static final String AGENT_CARD = """ { - "protocolVersion": "0.2.9", + "protocolVersions": ["0.2.9"], "name": "GeoSpatial Route Planner Agent", "description": "Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.", "supportedInterfaces" : [ @@ -73,7 +73,6 @@ public class JsonMessages { ] } ], - "supportsExtendedAgentCard": true, "signatures": [ { "protected": "eyJhbGciOiJFUzI1NiIsInR5cCI6IkpPU0UiLCJraWQiOiJrZXktMSIsImprdSI6Imh0dHBzOi8vZXhhbXBsZS5jb20vYWdlbnQvandrcy5qc29uIn0", diff --git a/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/A2AResponse.java b/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/A2AResponse.java index 73bb430eb..530f55e9f 100644 --- a/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/A2AResponse.java +++ b/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/A2AResponse.java @@ -10,7 +10,7 @@ * * @param the type of the result value returned in successful responses */ -public abstract sealed class A2AResponse implements A2AMessage permits CancelTaskResponse, DeleteTaskPushNotificationConfigResponse, GetAuthenticatedExtendedCardResponse, GetTaskPushNotificationConfigResponse, GetTaskResponse, A2AErrorResponse, ListTaskPushNotificationConfigResponse, ListTasksResponse, SendMessageResponse, SendStreamingMessageResponse, SetTaskPushNotificationConfigResponse { +public abstract sealed class A2AResponse implements A2AMessage permits CancelTaskResponse, DeleteTaskPushNotificationConfigResponse, GetExtendedAgentCardResponse, GetTaskPushNotificationConfigResponse, GetTaskResponse, A2AErrorResponse, ListTaskPushNotificationConfigResponse, ListTasksResponse, SendMessageResponse, SendStreamingMessageResponse, SetTaskPushNotificationConfigResponse { /** The JSON-RPC protocol version. */ protected String jsonrpc; diff --git a/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetAuthenticatedExtendedCardRequest.java b/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetExtendedAgentCardRequest.java similarity index 73% rename from jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetAuthenticatedExtendedCardRequest.java rename to jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetExtendedAgentCardRequest.java index dec5ec257..89e893363 100644 --- a/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetAuthenticatedExtendedCardRequest.java +++ b/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetExtendedAgentCardRequest.java @@ -4,8 +4,9 @@ import java.util.UUID; +import io.a2a.spec.AgentCapabilities; import io.a2a.spec.AgentCard; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; /** * JSON-RPC request to retrieve an agent's extended card with authenticated details. @@ -20,18 +21,18 @@ * *

* The agent must support authenticated extended cards (indicated by - * {@link AgentCard#supportsExtendedAgentCard()}) and the client must provide + * {@link AgentCapabilities#extendedAgentCard()} }) and the client must provide * valid authentication credentials for this request to succeed. *

- * This class implements the JSON-RPC {@code agent/getAuthenticatedExtendedCard} method + * This class implements the JSON-RPC {@code GetExtendedAgentCard} method * as specified in the A2A Protocol. * - * @see GetAuthenticatedExtendedCardResponse for the corresponding response + * @see GetExtendedAgentCardResponse for the corresponding response * @see AgentCard for the card structure - * @see ExtendedCardNotConfiguredError for the error when unsupported + * @see ExtendedAgentCardNotConfiguredError for the error when unsupported * @see A2A Protocol Specification */ -public final class GetAuthenticatedExtendedCardRequest extends NonStreamingJSONRPCRequest { +public final class GetExtendedAgentCardRequest extends NonStreamingJSONRPCRequest { /** * Constructs request with full parameters. @@ -39,7 +40,7 @@ public final class GetAuthenticatedExtendedCardRequest extends NonStreamingJSONR * @param jsonrpc the JSON-RPC version * @param id the request ID */ - public GetAuthenticatedExtendedCardRequest(String jsonrpc, Object id) { + public GetExtendedAgentCardRequest(String jsonrpc, Object id) { super(jsonrpc, GET_EXTENDED_AGENT_CARD_METHOD, id); } @@ -48,7 +49,7 @@ public GetAuthenticatedExtendedCardRequest(String jsonrpc, Object id) { * * @param id the request ID */ - public GetAuthenticatedExtendedCardRequest(String id) { + public GetExtendedAgentCardRequest(String id) { this(null, id); } @@ -80,7 +81,7 @@ private Builder() { * @param jsonrpc the JSON-RPC version * @return this builder for method chaining */ - public GetAuthenticatedExtendedCardRequest.Builder jsonrpc(String jsonrpc) { + public GetExtendedAgentCardRequest.Builder jsonrpc(String jsonrpc) { this.jsonrpc = jsonrpc; return this; } @@ -91,7 +92,7 @@ public GetAuthenticatedExtendedCardRequest.Builder jsonrpc(String jsonrpc) { * @param id the request ID * @return this builder for method chaining */ - public GetAuthenticatedExtendedCardRequest.Builder id(Object id) { + public GetExtendedAgentCardRequest.Builder id(Object id) { this.id = id; return this; } @@ -101,11 +102,11 @@ public GetAuthenticatedExtendedCardRequest.Builder id(Object id) { * * @return a new instance */ - public GetAuthenticatedExtendedCardRequest build() { + public GetExtendedAgentCardRequest build() { if (id == null) { id = UUID.randomUUID().toString(); } - return new GetAuthenticatedExtendedCardRequest(jsonrpc, id); + return new GetExtendedAgentCardRequest(jsonrpc, id); } } } diff --git a/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetAuthenticatedExtendedCardResponse.java b/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetExtendedAgentCardResponse.java similarity index 69% rename from jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetAuthenticatedExtendedCardResponse.java rename to jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetExtendedAgentCardResponse.java index 63b4fd8eb..edf181dd6 100644 --- a/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetAuthenticatedExtendedCardResponse.java +++ b/jsonrpc-common/src/main/java/io/a2a/jsonrpc/common/wrappers/GetExtendedAgentCardResponse.java @@ -2,7 +2,7 @@ import io.a2a.spec.A2AError; import io.a2a.spec.AgentCard; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; /** * JSON-RPC response containing an agent's extended card with authenticated details. @@ -13,14 +13,14 @@ *

* If the agent doesn't support authenticated extended cards or authentication fails, * the error field will contain a {@link A2AError} such as - * {@link ExtendedCardNotConfiguredError}. + * {@link ExtendedAgentCardNotConfiguredError}. * - * @see GetAuthenticatedExtendedCardRequest for the corresponding request + * @see GetExtendedAgentCardRequest for the corresponding request * @see AgentCard for the card structure - * @see ExtendedCardNotConfiguredError for the error when unsupported + * @see ExtendedAgentCardNotConfiguredError for the error when unsupported * @see A2A Protocol Specification */ -public final class GetAuthenticatedExtendedCardResponse extends A2AResponse { +public final class GetExtendedAgentCardResponse extends A2AResponse { /** * Constructs response with full parameters. @@ -30,7 +30,7 @@ public final class GetAuthenticatedExtendedCardResponse extends A2AResponse extends A2ARequest permits GetTaskRequest, CancelTaskRequest, SetTaskPushNotificationConfigRequest, GetTaskPushNotificationConfigRequest, SendMessageRequest, DeleteTaskPushNotificationConfigRequest, ListTaskPushNotificationConfigRequest, - GetAuthenticatedExtendedCardRequest, ListTasksRequest { + GetExtendedAgentCardRequest, ListTasksRequest { NonStreamingJSONRPCRequest(String jsonrpc, String method, Object id, T params) { validateAndSetJsonParameters(jsonrpc, method, id, params, true); diff --git a/jsonrpc-common/src/test/java/io/a2a/jsonrpc/common/json/SecuritySchemeSerializationTest.java b/jsonrpc-common/src/test/java/io/a2a/jsonrpc/common/json/SecuritySchemeSerializationTest.java index bbc297baa..5a5f3d856 100644 --- a/jsonrpc-common/src/test/java/io/a2a/jsonrpc/common/json/SecuritySchemeSerializationTest.java +++ b/jsonrpc-common/src/test/java/io/a2a/jsonrpc/common/json/SecuritySchemeSerializationTest.java @@ -17,10 +17,7 @@ import io.a2a.spec.APIKeySecurityScheme; import io.a2a.spec.HTTPAuthSecurityScheme; import io.a2a.spec.MutualTLSSecurityScheme; -import io.a2a.spec.OAuth2SecurityScheme; -import io.a2a.spec.OAuthFlows; import io.a2a.spec.OpenIdConnectSecurityScheme; -import io.a2a.spec.PasswordOAuthFlow; import io.a2a.spec.SecurityScheme; /** @@ -128,68 +125,6 @@ void testAPIKeySecuritySchemeWithDescriptionSerialization() throws JsonProcessin "description", "API key authentication via query parameter")); } - @Test - void testOAuth2SecuritySchemeSerialization() throws JsonProcessingException { - PasswordOAuthFlow passwordFlow = new PasswordOAuthFlow( - "https://example.com/oauth/refresh", - Map.of("read", "Read access", "write", "Write access"), - "https://example.com/oauth/token" - ); - - OAuthFlows flows = OAuthFlows.builder() - .password(passwordFlow) - .build(); - - SecurityScheme scheme = OAuth2SecurityScheme.builder() - .flows(flows) - .description("OAuth 2.0 password flow") - .oauth2MetadataUrl("https://example.com/.well-known/oauth-authorization-server") - .build(); - - // Verify serialization with nested OAuth flow fields - String json = JsonUtil.toJson(scheme); - assertNotNull(json); - assertTrue(json.contains(OAuth2SecurityScheme.TYPE)); - assertTrue(json.contains("\"description\":\"OAuth 2.0 password flow\"")); - assertTrue(json.contains("\"oauth2MetadataUrl\":\"https://example.com/.well-known/oauth-authorization-server\"")); - assertTrue(json.contains("\"tokenUrl\":\"https://example.com/oauth/token\"")); - assertTrue(json.contains("\"read\":\"Read access\"")); - - SecurityScheme deserialized = JsonUtil.fromJson(json, SecurityScheme.class); - assertEquals(scheme, deserialized); - } - - @Test - void testOAuth2SecuritySchemeDeserialization() throws JsonProcessingException { - String json = """ - { - "oauth2SecurityScheme" : { - "flows": { - "password": { - "tokenUrl": "https://example.com/oauth/token", - "refreshUrl": "https://example.com/oauth/refresh", - "scopes": { - "read": "Read access", - "write": "Write access" - } - } - }, - "description": "OAuth 2.0 authentication" - } - }"""; - - SecurityScheme securityScheme = JsonUtil.fromJson(json, SecurityScheme.class); - assertInstanceOf(OAuth2SecurityScheme.class, securityScheme); - OAuth2SecurityScheme scheme = (OAuth2SecurityScheme) securityScheme; - assertEquals("OAuth 2.0 authentication", scheme.description()); - assertNotNull(scheme.flows()); - assertNotNull(scheme.flows().password()); - assertEquals("https://example.com/oauth/token", scheme.flows().password().tokenUrl()); - assertEquals("https://example.com/oauth/refresh", scheme.flows().password().refreshUrl()); - assertEquals(2, scheme.flows().password().scopes().size()); - assertEquals("Read access", scheme.flows().password().scopes().get("read")); - } - @Test void testOpenIdConnectSecuritySchemeSerialization() throws JsonProcessingException { SecurityScheme scheme = OpenIdConnectSecurityScheme.builder() diff --git a/reference/grpc/src/main/java/io/a2a/server/grpc/quarkus/QuarkusGrpcHandler.java b/reference/grpc/src/main/java/io/a2a/server/grpc/quarkus/QuarkusGrpcHandler.java index edd346d50..e5f7a27c2 100644 --- a/reference/grpc/src/main/java/io/a2a/server/grpc/quarkus/QuarkusGrpcHandler.java +++ b/reference/grpc/src/main/java/io/a2a/server/grpc/quarkus/QuarkusGrpcHandler.java @@ -5,6 +5,7 @@ import jakarta.enterprise.inject.Instance; import jakarta.inject.Inject; +import io.a2a.server.ExtendedAgentCard; import io.a2a.server.PublicAgentCard; import io.a2a.server.requesthandlers.RequestHandler; import io.a2a.server.util.async.Internal; @@ -14,6 +15,7 @@ import io.quarkus.grpc.GrpcService; import io.quarkus.grpc.RegisterInterceptor; import io.quarkus.security.Authenticated; +import org.jspecify.annotations.Nullable; @GrpcService @RegisterInterceptor(A2AExtensionsInterceptor.class) @@ -21,16 +23,29 @@ public class QuarkusGrpcHandler extends GrpcHandler { private final AgentCard agentCard; + private final AgentCard extendedAgentCard; private final RequestHandler requestHandler; private final Instance callContextFactoryInstance; private final Executor executor; + /** + * No-args constructor for CDI proxy creation. + * CDI requires a non-private constructor to create proxies for @ApplicationScoped beans. + * All fields are initialized by the @Inject constructor during actual bean creation. + */ + @Inject public QuarkusGrpcHandler(@PublicAgentCard AgentCard agentCard, + @ExtendedAgentCard Instance extendedAgentCard, RequestHandler requestHandler, Instance callContextFactoryInstance, @Internal Executor executor) { this.agentCard = agentCard; + if (extendedAgentCard != null && extendedAgentCard.isResolvable()) { + this.extendedAgentCard = extendedAgentCard.get(); + } else { + this.extendedAgentCard = null; + } this.requestHandler = requestHandler; this.callContextFactoryInstance = callContextFactoryInstance; this.executor = executor; @@ -46,6 +61,11 @@ protected AgentCard getAgentCard() { return agentCard; } + @Override + protected AgentCard getExtendedAgentCard() { + return extendedAgentCard; + } + @Override protected CallContextFactory getCallContextFactory() { return callContextFactoryInstance.isUnsatisfied() ? null : callContextFactoryInstance.get(); diff --git a/reference/jsonrpc/src/main/java/io/a2a/server/apps/quarkus/A2AServerRoutes.java b/reference/jsonrpc/src/main/java/io/a2a/server/apps/quarkus/A2AServerRoutes.java index 9f4b31d83..18e18a2f1 100644 --- a/reference/jsonrpc/src/main/java/io/a2a/server/apps/quarkus/A2AServerRoutes.java +++ b/reference/jsonrpc/src/main/java/io/a2a/server/apps/quarkus/A2AServerRoutes.java @@ -35,8 +35,8 @@ import io.a2a.jsonrpc.common.wrappers.CancelTaskResponse; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigResponse; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardRequest; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardResponse; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardRequest; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskRequest; @@ -59,7 +59,6 @@ import io.a2a.server.extensions.A2AExtensions; import io.a2a.server.util.async.Internal; import io.a2a.spec.A2AError; -import io.a2a.spec.AgentCard; import io.a2a.spec.InternalError; import io.a2a.spec.JSONParseError; import io.a2a.spec.UnsupportedOperationError; @@ -186,8 +185,8 @@ private A2AResponse processNonStreamingRequest(NonStreamingJSONRPCRequest if (request instanceof DeleteTaskPushNotificationConfigRequest req) { return jsonRpcHandler.deletePushNotificationConfig(req, context); } - if (request instanceof GetAuthenticatedExtendedCardRequest req) { - return jsonRpcHandler.onGetAuthenticatedExtendedCardRequest(req, context); + if (request instanceof GetExtendedAgentCardRequest req) { + return jsonRpcHandler.onGetExtendedCardRequest(req, context); } return generateErrorResponse(request, new UnsupportedOperationError()); } @@ -287,8 +286,8 @@ private static com.google.protobuf.MessageOrBuilder convertToProto(A2AResponse contextCaptor = ArgumentCaptor.forClass(ServerCallContext.class); @@ -513,8 +513,8 @@ public void testGetAuthenticatedExtendedCard_MethodNameSetInContext() { routes.invokeJSONRPCHandler(jsonRpcRequest, mockRoutingContext); // Assert - verify(mockJsonRpcHandler).onGetAuthenticatedExtendedCardRequest( - any(GetAuthenticatedExtendedCardRequest.class), contextCaptor.capture()); + verify(mockJsonRpcHandler).onGetExtendedCardRequest( + any(GetExtendedAgentCardRequest.class), contextCaptor.capture()); ServerCallContext capturedContext = contextCaptor.getValue(); assertNotNull(capturedContext); assertEquals(GET_EXTENDED_AGENT_CARD_METHOD, capturedContext.getState().get(METHOD_NAME_KEY)); diff --git a/server-common/src/main/java/io/a2a/server/requesthandlers/DefaultRequestHandler.java b/server-common/src/main/java/io/a2a/server/requesthandlers/DefaultRequestHandler.java index e19f7920d..002acbafd 100644 --- a/server-common/src/main/java/io/a2a/server/requesthandlers/DefaultRequestHandler.java +++ b/server-common/src/main/java/io/a2a/server/requesthandlers/DefaultRequestHandler.java @@ -312,19 +312,27 @@ private static Task limitTaskHistory(Task task, @Nullable Integer historyLength) @Override public ListTasksResult onListTasks(ListTasksParams params, ServerCallContext context) throws A2AError { - LOGGER.debug("onListTasks with contextId={}, status={}, pageSize={}, pageToken={}, lastUpdatedAfter={}", - params.contextId(), params.status(), params.pageSize(), params.pageToken(), params.lastUpdatedAfter()); + LOGGER.debug("onListTasks with contextId={}, status={}, pageSize={}, pageToken={}, statusTimestampAfter={}", + params.contextId(), params.status(), params.pageSize(), params.pageToken(), params.statusTimestampAfter()); - // Validate lastUpdatedAfter timestamp if provided - if (params.lastUpdatedAfter() != null) { + // Validate statusTimestampAfter timestamp if provided + if (params.statusTimestampAfter() != null) { // Check if timestamp is in the future (optional validation per spec) Instant now = Instant.now(); - if (params.lastUpdatedAfter().isAfter(now)) { + if (params.statusTimestampAfter().isAfter(now)) { Map errorData = new HashMap<>(); errorData.put("parameter", "lastUpdatedAfter"); errorData.put("reason", "Timestamp cannot be in the future"); throw new InvalidParamsError(null, "Invalid params", errorData); } + // Check that timestamp is not negative + long millis = params.statusTimestampAfter().toEpochMilli(); + if (millis < 0L) { + Map errorData = new HashMap<>(); + errorData.put("parameter", "statusTimestampAfter"); + errorData.put("reason", "Must be a non-negative timestamp value, got: " + millis); + throw new InvalidParamsError(null, "Invalid params", errorData); + } } ListTasksResult result = taskStore.list(params); diff --git a/server-common/src/main/java/io/a2a/server/tasks/InMemoryTaskStore.java b/server-common/src/main/java/io/a2a/server/tasks/InMemoryTaskStore.java index f1243e272..8a3d72133 100644 --- a/server-common/src/main/java/io/a2a/server/tasks/InMemoryTaskStore.java +++ b/server-common/src/main/java/io/a2a/server/tasks/InMemoryTaskStore.java @@ -52,10 +52,10 @@ public ListTasksResult list(ListTasksParams params) { .filter(task -> params.contextId() == null || params.contextId().equals(task.contextId())) .filter(task -> params.status() == null || (task.status() != null && params.status().equals(task.status().state()))) - .filter(task -> params.lastUpdatedAfter() == null || + .filter(task -> params.statusTimestampAfter() == null || (task.status() != null && task.status().timestamp() != null && - task.status().timestamp().toInstant().isAfter(params.lastUpdatedAfter()))) + task.status().timestamp().toInstant().isAfter(params.statusTimestampAfter()))) .sorted(Comparator.comparing( (Task t) -> (t.status() != null && t.status().timestamp() != null) // Truncate to milliseconds for consistency with pageToken precision diff --git a/server-common/src/main/java/io/a2a/server/version/A2AVersionValidator.java b/server-common/src/main/java/io/a2a/server/version/A2AVersionValidator.java index 83a83122f..91159428a 100644 --- a/server-common/src/main/java/io/a2a/server/version/A2AVersionValidator.java +++ b/server-common/src/main/java/io/a2a/server/version/A2AVersionValidator.java @@ -1,5 +1,7 @@ package io.a2a.server.version; +import java.util.List; + import io.a2a.server.ServerCallContext; import io.a2a.spec.AgentCard; import io.a2a.spec.VersionNotSupportedError; @@ -35,13 +37,13 @@ public static void validateProtocolVersion(AgentCard agentCard, ServerCallContex requestedVersion = AgentCard.CURRENT_PROTOCOL_VERSION; } - String supportedVersion = agentCard.protocolVersion(); + List supportedVersions = agentCard.protocolVersions(); - if (!isVersionCompatible(supportedVersion, requestedVersion)) { + if (!isVersionCompatible(supportedVersions, requestedVersion)) { throw new VersionNotSupportedError( null, "Protocol version '" + requestedVersion + "' is not supported. " + - "Supported version: " + supportedVersion, + "Supported versions: " + supportedVersions, null); } } @@ -55,22 +57,30 @@ public static void validateProtocolVersion(AgentCard agentCard, ServerCallContex *

  • Minor versions are compatible (any x.Y works with x.Z)
  • * * - * @param supported the version supported by the agent (e.g., "1.0") - * @param requested the version requested by the client (e.g., "1.1") + * @param supportedVersions the version supported by the agent (e.g., ["1.0", "1.1"]) + * @param requestedVersion the version requested by the client (e.g., "1.1") * @return true if versions are compatible, false otherwise */ - static boolean isVersionCompatible(String supported, String requested) { - try { - VersionParts supportedParts = parseVersion(supported); - VersionParts requestedParts = parseVersion(requested); - - // Major versions must match exactly - return supportedParts.major == requestedParts.major; - // Minor versions are compatible - any 1.x can talk to any 1.y - } catch (IllegalArgumentException e) { - // If we can't parse the version, consider it incompatible + static boolean isVersionCompatible(List supportedVersions, String requestedVersion) { + if (supportedVersions == null) { return false; } + for (String supportedVersion : supportedVersions) { + try { + VersionParts supportedParts = parseVersion(supportedVersion); + VersionParts requestedParts = parseVersion(requestedVersion); + + // Major versions must match exactly + if (supportedParts.major == requestedParts.major) { + return true; + } + // Minor versions are compatible - any 1.x can talk to any 1.y + } catch (IllegalArgumentException e) { + // If we can't parse the version, consider it incompatible + return false; + } + } + return false; } /** diff --git a/server-common/src/test/java/io/a2a/server/requesthandlers/AbstractA2ARequestHandlerTest.java b/server-common/src/test/java/io/a2a/server/requesthandlers/AbstractA2ARequestHandlerTest.java index 8038bc147..ea5bbe797 100644 --- a/server-common/src/test/java/io/a2a/server/requesthandlers/AbstractA2ARequestHandlerTest.java +++ b/server-common/src/test/java/io/a2a/server/requesthandlers/AbstractA2ARequestHandlerTest.java @@ -127,7 +127,7 @@ protected static AgentCard createAgentCard(boolean streaming, boolean pushNotifi .defaultInputModes(new ArrayList<>()) .defaultOutputModes(new ArrayList<>()) .skills(new ArrayList<>()) - .protocolVersion(CURRENT_PROTOCOL_VERSION); + .protocolVersions(CURRENT_PROTOCOL_VERSION); return builder.build(); } diff --git a/server-common/src/test/java/io/a2a/server/version/A2AVersionValidatorTest.java b/server-common/src/test/java/io/a2a/server/version/A2AVersionValidatorTest.java index 528017731..43e0f55dd 100644 --- a/server-common/src/test/java/io/a2a/server/version/A2AVersionValidatorTest.java +++ b/server-common/src/test/java/io/a2a/server/version/A2AVersionValidatorTest.java @@ -18,34 +18,34 @@ public class A2AVersionValidatorTest { @Test public void testIsVersionCompatible_SameMajorMinor() { - assertTrue(A2AVersionValidator.isVersionCompatible("1.0", "1.0")); + assertTrue(A2AVersionValidator.isVersionCompatible(List.of("1.0"), "1.0")); } @Test public void testIsVersionCompatible_SameMajorDifferentMinor() { // Major versions match, minor versions can differ - assertTrue(A2AVersionValidator.isVersionCompatible("1.0", "1.1")); - assertTrue(A2AVersionValidator.isVersionCompatible("1.1", "1.0")); - assertTrue(A2AVersionValidator.isVersionCompatible("1.5", "1.9")); + assertTrue(A2AVersionValidator.isVersionCompatible(List.of("1.0"), "1.1")); + assertTrue(A2AVersionValidator.isVersionCompatible(List.of("1.1"), "1.0")); + assertTrue(A2AVersionValidator.isVersionCompatible(List.of("1.5"), "1.9")); } @Test public void testIsVersionCompatible_DifferentMajor() { // Major versions must match exactly - assertFalse(A2AVersionValidator.isVersionCompatible("1.0", "2.0")); - assertFalse(A2AVersionValidator.isVersionCompatible("2.0", "1.0")); - assertFalse(A2AVersionValidator.isVersionCompatible("1.5", "2.5")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("1.0"), "2.0")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("2.0"), "1.0")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("1.5"), "2.5")); } @Test public void testIsVersionCompatible_InvalidFormat() { // Invalid version formats should return false - assertFalse(A2AVersionValidator.isVersionCompatible("1.0", "invalid")); - assertFalse(A2AVersionValidator.isVersionCompatible("invalid", "1.0")); - assertFalse(A2AVersionValidator.isVersionCompatible("1", "1.0")); - assertFalse(A2AVersionValidator.isVersionCompatible("1.0", "")); - assertFalse(A2AVersionValidator.isVersionCompatible("", "1.0")); - assertFalse(A2AVersionValidator.isVersionCompatible("1.0", null)); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("1.0"), "invalid")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("invalid"), "1.0")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("1"), "1.0")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("1.0"), "")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of(""), "1.0")); + assertFalse(A2AVersionValidator.isVersionCompatible(List.of("1.0"), null)); assertFalse(A2AVersionValidator.isVersionCompatible(null, "1.0")); } @@ -153,7 +153,7 @@ private AgentCard createAgentCard(String protocolVersion) { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(Collections.emptyList()) - .protocolVersion(protocolVersion) + .protocolVersions(protocolVersion) .build(); } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/A2A.java b/spec-grpc/src/main/java/io/a2a/grpc/A2A.java index bc454f7e1..0fa06787b 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/A2A.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/A2A.java @@ -202,25 +202,15 @@ public static void registerAllExtensions( com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_a2a_v1_ClientCredentialsOAuthFlow_ScopesEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_a2a_v1_ImplicitOAuthFlow_descriptor; + internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_a2a_v1_ImplicitOAuthFlow_fieldAccessorTable; + internal_static_a2a_v1_DeviceCodeOAuthFlow_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_a2a_v1_ImplicitOAuthFlow_ScopesEntry_descriptor; + internal_static_a2a_v1_DeviceCodeOAuthFlow_ScopesEntry_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_a2a_v1_ImplicitOAuthFlow_ScopesEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_a2a_v1_PasswordOAuthFlow_descriptor; - static final - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_a2a_v1_PasswordOAuthFlow_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_a2a_v1_PasswordOAuthFlow_ScopesEntry_descriptor; - static final - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_a2a_v1_PasswordOAuthFlow_ScopesEntry_fieldAccessorTable; + internal_static_a2a_v1_DeviceCodeOAuthFlow_ScopesEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_a2a_v1_SendMessageRequest_descriptor; static final @@ -352,199 +342,191 @@ public static void registerAllExtensions( "\n\007schemes\030\001 \003(\tB\003\340A\002\022\023\n\013credentials\030\002 \001(" + "\t\"Q\n\016AgentInterface\022\020\n\003url\030\001 \001(\tB\003\340A\002\022\035\n" + "\020protocol_binding\030\002 \001(\tB\003\340A\002\022\016\n\006tenant\030\003" + - " \001(\t\"\255\007\n\tAgentCard\022\"\n\020protocol_version\030\020" + - " \001(\tB\003\340A\002H\000\210\001\001\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\030\n\013des" + - "cription\030\002 \001(\tB\003\340A\002\0224\n\024supported_interfa" + - "ces\030\023 \003(\0132\026.a2a.v1.AgentInterface\022\024\n\003url" + - "\030\003 \001(\tB\002\030\001H\001\210\001\001\022$\n\023preferred_transport\030\016" + - " \001(\tB\002\030\001H\002\210\001\001\0229\n\025additional_interfaces\030\017" + - " \003(\0132\026.a2a.v1.AgentInterfaceB\002\030\001\022\'\n\010prov" + - "ider\030\004 \001(\0132\025.a2a.v1.AgentProvider\022\024\n\007ver" + - "sion\030\005 \001(\tB\003\340A\002\022\036\n\021documentation_url\030\006 \001" + - "(\tH\003\210\001\001\0224\n\014capabilities\030\007 \001(\0132\031.a2a.v1.A" + - "gentCapabilitiesB\003\340A\002\022@\n\020security_scheme" + - "s\030\010 \003(\0132&.a2a.v1.AgentCard.SecuritySchem" + - "esEntry\022\"\n\010security\030\t \003(\0132\020.a2a.v1.Secur" + - "ity\022 \n\023default_input_modes\030\n \003(\tB\003\340A\002\022!\n" + - "\024default_output_modes\030\013 \003(\tB\003\340A\002\022\'\n\006skil" + - "ls\030\014 \003(\0132\022.a2a.v1.AgentSkillB\003\340A\002\022)\n\034sup" + - "ports_extended_agent_card\030\r \001(\010H\004\210\001\001\022.\n\n" + - "signatures\030\021 \003(\0132\032.a2a.v1.AgentCardSigna" + - "ture\022\025\n\010icon_url\030\022 \001(\tH\005\210\001\001\032N\n\024SecurityS" + - "chemesEntry\022\013\n\003key\030\001 \001(\t\022%\n\005value\030\002 \001(\0132" + - "\026.a2a.v1.SecurityScheme:\0028\001B\023\n\021_protocol" + - "_versionB\006\n\004_urlB\026\n\024_preferred_transport" + - "B\024\n\022_documentation_urlB\037\n\035_supports_exte" + - "nded_agent_cardB\013\n\t_icon_url\"<\n\rAgentPro" + - "vider\022\020\n\003url\030\001 \001(\tB\003\340A\002\022\031\n\014organization\030" + - "\002 \001(\tB\003\340A\002\"\341\001\n\021AgentCapabilities\022\026\n\tstre" + - "aming\030\001 \001(\010H\000\210\001\001\022\037\n\022push_notifications\030\002" + - " \001(\010H\001\210\001\001\022*\n\nextensions\030\003 \003(\0132\026.a2a.v1.A" + - "gentExtension\022%\n\030state_transition_histor" + - "y\030\004 \001(\010H\002\210\001\001B\014\n\n_streamingB\025\n\023_push_noti" + - "ficationsB\033\n\031_state_transition_history\"m" + - "\n\016AgentExtension\022\013\n\003uri\030\001 \001(\t\022\023\n\013descrip" + - "tion\030\002 \001(\t\022\020\n\010required\030\003 \001(\010\022\'\n\006params\030\004" + - " \001(\0132\027.google.protobuf.Struct\"\276\001\n\nAgentS" + - "kill\022\017\n\002id\030\001 \001(\tB\003\340A\002\022\021\n\004name\030\002 \001(\tB\003\340A\002" + - "\022\030\n\013description\030\003 \001(\tB\003\340A\002\022\021\n\004tags\030\004 \003(\t" + - "B\003\340A\002\022\020\n\010examples\030\005 \003(\t\022\023\n\013input_modes\030\006" + - " \003(\t\022\024\n\014output_modes\030\007 \003(\t\022\"\n\010security\030\010" + - " \003(\0132\020.a2a.v1.Security\"m\n\022AgentCardSigna" + - "ture\022\026\n\tprotected\030\001 \001(\tB\003\340A\002\022\026\n\tsignatur" + - "e\030\002 \001(\tB\003\340A\002\022\'\n\006header\030\003 \001(\0132\027.google.pr" + - "otobuf.Struct\"v\n\032TaskPushNotificationCon" + - "fig\022\021\n\004name\030\001 \001(\tB\003\340A\002\022E\n\030push_notificat" + - "ion_config\030\002 \001(\0132\036.a2a.v1.PushNotificati" + - "onConfigB\003\340A\002\"\032\n\nStringList\022\014\n\004list\030\001 \003(" + - "\t\"~\n\010Security\022.\n\007schemes\030\001 \003(\0132\035.a2a.v1." + - "Security.SchemesEntry\032B\n\014SchemesEntry\022\013\n" + - "\003key\030\001 \001(\t\022!\n\005value\030\002 \001(\0132\022.a2a.v1.Strin" + - "gList:\0028\001\"\361\002\n\016SecurityScheme\022?\n\027api_key_" + - "security_scheme\030\001 \001(\0132\034.a2a.v1.APIKeySec" + - "uritySchemeH\000\022C\n\031http_auth_security_sche" + - "me\030\002 \001(\0132\036.a2a.v1.HTTPAuthSecurityScheme" + - "H\000\022>\n\026oauth2_security_scheme\030\003 \001(\0132\034.a2a" + - ".v1.OAuth2SecuritySchemeH\000\022N\n\037open_id_co" + - "nnect_security_scheme\030\004 \001(\0132#.a2a.v1.Ope" + - "nIdConnectSecuritySchemeH\000\022?\n\024mtls_secur" + - "ity_scheme\030\005 \001(\0132\037.a2a.v1.MutualTlsSecur" + - "itySchemeH\000B\010\n\006scheme\"U\n\024APIKeySecurityS" + - "cheme\022\023\n\013description\030\001 \001(\t\022\025\n\010location\030\002" + - " \001(\tB\003\340A\002\022\021\n\004name\030\003 \001(\tB\003\340A\002\"Y\n\026HTTPAuth" + - "SecurityScheme\022\023\n\013description\030\001 \001(\t\022\023\n\006s" + - "cheme\030\002 \001(\tB\003\340A\002\022\025\n\rbearer_format\030\003 \001(\t\"" + - "p\n\024OAuth2SecurityScheme\022\023\n\013description\030\001" + - " \001(\t\022&\n\005flows\030\002 \001(\0132\022.a2a.v1.OAuthFlowsB" + - "\003\340A\002\022\033\n\023oauth2_metadata_url\030\003 \001(\t\"T\n\033Ope" + - "nIdConnectSecurityScheme\022\023\n\013description\030" + - "\001 \001(\t\022 \n\023open_id_connect_url\030\002 \001(\tB\003\340A\002\"" + - ".\n\027MutualTlsSecurityScheme\022\023\n\013descriptio" + - "n\030\001 \001(\t\"\366\001\n\nOAuthFlows\022@\n\022authorization_" + - "code\030\001 \001(\0132\".a2a.v1.AuthorizationCodeOAu" + - "thFlowH\000\022@\n\022client_credentials\030\002 \001(\0132\".a" + - "2a.v1.ClientCredentialsOAuthFlowH\000\022-\n\010im" + - "plicit\030\003 \001(\0132\031.a2a.v1.ImplicitOAuthFlowH" + - "\000\022-\n\010password\030\004 \001(\0132\031.a2a.v1.PasswordOAu" + - "thFlowH\000B\006\n\004flow\"\335\001\n\032AuthorizationCodeOA" + - "uthFlow\022\036\n\021authorization_url\030\001 \001(\tB\003\340A\002\022" + - "\026\n\ttoken_url\030\002 \001(\tB\003\340A\002\022\023\n\013refresh_url\030\003" + - " \001(\t\022C\n\006scopes\030\004 \003(\0132..a2a.v1.Authorizat" + - "ionCodeOAuthFlow.ScopesEntryB\003\340A\002\032-\n\013Sco" + - "pesEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001" + - "\"\275\001\n\032ClientCredentialsOAuthFlow\022\026\n\ttoken" + - "_url\030\001 \001(\tB\003\340A\002\022\023\n\013refresh_url\030\002 \001(\t\022C\n\006" + - "scopes\030\003 \003(\0132..a2a.v1.ClientCredentialsO" + - "AuthFlow.ScopesEntryB\003\340A\002\032-\n\013ScopesEntry" + - "\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\263\001\n\021Imp" + - "licitOAuthFlow\022\036\n\021authorization_url\030\001 \001(" + - "\tB\003\340A\002\022\023\n\013refresh_url\030\002 \001(\t\022:\n\006scopes\030\003 " + - "\003(\0132%.a2a.v1.ImplicitOAuthFlow.ScopesEnt" + + " \001(\t\"\310\005\n\tAgentCard\022\036\n\021protocol_versions\030" + + "\020 \003(\tB\003\340A\002\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\030\n\013descrip" + + "tion\030\002 \001(\tB\003\340A\002\0229\n\024supported_interfaces\030" + + "\023 \003(\0132\026.a2a.v1.AgentInterfaceB\003\340A\002\022\'\n\010pr" + + "ovider\030\004 \001(\0132\025.a2a.v1.AgentProvider\022\024\n\007v" + + "ersion\030\005 \001(\tB\003\340A\002\022\036\n\021documentation_url\030\006" + + " \001(\tH\000\210\001\001\0224\n\014capabilities\030\007 \001(\0132\031.a2a.v1" + + ".AgentCapabilitiesB\003\340A\002\022@\n\020security_sche" + + "mes\030\010 \003(\0132&.a2a.v1.AgentCard.SecuritySch" + + "emesEntry\022\"\n\010security\030\t \003(\0132\020.a2a.v1.Sec" + + "urity\022 \n\023default_input_modes\030\n \003(\tB\003\340A\002\022" + + "!\n\024default_output_modes\030\013 \003(\tB\003\340A\002\022\'\n\006sk" + + "ills\030\014 \003(\0132\022.a2a.v1.AgentSkillB\003\340A\002\022.\n\ns" + + "ignatures\030\021 \003(\0132\032.a2a.v1.AgentCardSignat" + + "ure\022\025\n\010icon_url\030\022 \001(\tH\001\210\001\001\032N\n\024SecuritySc" + + "hemesEntry\022\013\n\003key\030\001 \001(\t\022%\n\005value\030\002 \001(\0132\026" + + ".a2a.v1.SecurityScheme:\0028\001B\024\n\022_documenta" + + "tion_urlB\013\n\t_icon_urlJ\004\010\003\020\004J\004\010\016\020\017J\004\010\017\020\020\"" + + "<\n\rAgentProvider\022\020\n\003url\030\001 \001(\tB\003\340A\002\022\031\n\014or" + + "ganization\030\002 \001(\tB\003\340A\002\"\233\002\n\021AgentCapabilit" + + "ies\022\026\n\tstreaming\030\001 \001(\010H\000\210\001\001\022\037\n\022push_noti" + + "fications\030\002 \001(\010H\001\210\001\001\022*\n\nextensions\030\003 \003(\013" + + "2\026.a2a.v1.AgentExtension\022%\n\030state_transi" + + "tion_history\030\004 \001(\010H\002\210\001\001\022 \n\023extended_agen" + + "t_card\030\005 \001(\010H\003\210\001\001B\014\n\n_streamingB\025\n\023_push" + + "_notificationsB\033\n\031_state_transition_hist" + + "oryB\026\n\024_extended_agent_card\"m\n\016AgentExte" + + "nsion\022\013\n\003uri\030\001 \001(\t\022\023\n\013description\030\002 \001(\t\022" + + "\020\n\010required\030\003 \001(\010\022\'\n\006params\030\004 \001(\0132\027.goog" + + "le.protobuf.Struct\"\276\001\n\nAgentSkill\022\017\n\002id\030" + + "\001 \001(\tB\003\340A\002\022\021\n\004name\030\002 \001(\tB\003\340A\002\022\030\n\013descrip" + + "tion\030\003 \001(\tB\003\340A\002\022\021\n\004tags\030\004 \003(\tB\003\340A\002\022\020\n\010ex" + + "amples\030\005 \003(\t\022\023\n\013input_modes\030\006 \003(\t\022\024\n\014out" + + "put_modes\030\007 \003(\t\022\"\n\010security\030\010 \003(\0132\020.a2a." + + "v1.Security\"m\n\022AgentCardSignature\022\026\n\tpro" + + "tected\030\001 \001(\tB\003\340A\002\022\026\n\tsignature\030\002 \001(\tB\003\340A" + + "\002\022\'\n\006header\030\003 \001(\0132\027.google.protobuf.Stru" + + "ct\"v\n\032TaskPushNotificationConfig\022\021\n\004name" + + "\030\001 \001(\tB\003\340A\002\022E\n\030push_notification_config\030" + + "\002 \001(\0132\036.a2a.v1.PushNotificationConfigB\003\340" + + "A\002\"\032\n\nStringList\022\014\n\004list\030\001 \003(\t\"~\n\010Securi" + + "ty\022.\n\007schemes\030\001 \003(\0132\035.a2a.v1.Security.Sc" + + "hemesEntry\032B\n\014SchemesEntry\022\013\n\003key\030\001 \001(\t\022" + + "!\n\005value\030\002 \001(\0132\022.a2a.v1.StringList:\0028\001\"\361" + + "\002\n\016SecurityScheme\022?\n\027api_key_security_sc" + + "heme\030\001 \001(\0132\034.a2a.v1.APIKeySecurityScheme" + + "H\000\022C\n\031http_auth_security_scheme\030\002 \001(\0132\036." + + "a2a.v1.HTTPAuthSecuritySchemeH\000\022>\n\026oauth" + + "2_security_scheme\030\003 \001(\0132\034.a2a.v1.OAuth2S" + + "ecuritySchemeH\000\022N\n\037open_id_connect_secur" + + "ity_scheme\030\004 \001(\0132#.a2a.v1.OpenIdConnectS" + + "ecuritySchemeH\000\022?\n\024mtls_security_scheme\030" + + "\005 \001(\0132\037.a2a.v1.MutualTlsSecuritySchemeH\000" + + "B\010\n\006scheme\"U\n\024APIKeySecurityScheme\022\023\n\013de" + + "scription\030\001 \001(\t\022\025\n\010location\030\002 \001(\tB\003\340A\002\022\021" + + "\n\004name\030\003 \001(\tB\003\340A\002\"Y\n\026HTTPAuthSecuritySch" + + "eme\022\023\n\013description\030\001 \001(\t\022\023\n\006scheme\030\002 \001(\t" + + "B\003\340A\002\022\025\n\rbearer_format\030\003 \001(\t\"p\n\024OAuth2Se" + + "curityScheme\022\023\n\013description\030\001 \001(\t\022&\n\005flo" + + "ws\030\002 \001(\0132\022.a2a.v1.OAuthFlowsB\003\340A\002\022\033\n\023oau" + + "th2_metadata_url\030\003 \001(\t\"T\n\033OpenIdConnectS" + + "ecurityScheme\022\023\n\013description\030\001 \001(\t\022 \n\023op" + + "en_id_connect_url\030\002 \001(\tB\003\340A\002\".\n\027MutualTl" + + "sSecurityScheme\022\023\n\013description\030\001 \001(\t\"\330\001\n" + + "\nOAuthFlows\022@\n\022authorization_code\030\001 \001(\0132" + + "\".a2a.v1.AuthorizationCodeOAuthFlowH\000\022@\n" + + "\022client_credentials\030\002 \001(\0132\".a2a.v1.Clien" + + "tCredentialsOAuthFlowH\000\0222\n\013device_code\030\005" + + " \001(\0132\033.a2a.v1.DeviceCodeOAuthFlowH\000B\006\n\004f" + + "lowJ\004\010\003\020\004J\004\010\004\020\005\"\364\001\n\032AuthorizationCodeOAu" + + "thFlow\022\036\n\021authorization_url\030\001 \001(\tB\003\340A\002\022\026" + + "\n\ttoken_url\030\002 \001(\tB\003\340A\002\022\023\n\013refresh_url\030\003 " + + "\001(\t\022C\n\006scopes\030\004 \003(\0132..a2a.v1.Authorizati" + + "onCodeOAuthFlow.ScopesEntryB\003\340A\002\022\025\n\rpkce" + + "_required\030\005 \001(\010\032-\n\013ScopesEntry\022\013\n\003key\030\001 " + + "\001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\275\001\n\032ClientCredent" + + "ialsOAuthFlow\022\026\n\ttoken_url\030\001 \001(\tB\003\340A\002\022\023\n" + + "\013refresh_url\030\002 \001(\t\022C\n\006scopes\030\003 \003(\0132..a2a" + + ".v1.ClientCredentialsOAuthFlow.ScopesEnt" + "ryB\003\340A\002\032-\n\013ScopesEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005v" + - "alue\030\002 \001(\t:\0028\001\"\253\001\n\021PasswordOAuthFlow\022\026\n\t" + - "token_url\030\001 \001(\tB\003\340A\002\022\023\n\013refresh_url\030\002 \001(" + - "\t\022:\n\006scopes\030\003 \003(\0132%.a2a.v1.PasswordOAuth" + - "Flow.ScopesEntryB\003\340A\002\032-\n\013ScopesEntry\022\013\n\003" + - "key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\270\001\n\022SendMes" + - "sageRequest\022\016\n\006tenant\030\004 \001(\t\022.\n\007request\030\001" + - " \001(\0132\017.a2a.v1.MessageB\003\340A\002R\007message\0227\n\rc" + - "onfiguration\030\002 \001(\0132 .a2a.v1.SendMessageC" + - "onfiguration\022)\n\010metadata\030\003 \001(\0132\027.google." + - "protobuf.Struct\"c\n\016GetTaskRequest\022\016\n\006ten" + - "ant\030\003 \001(\t\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\033\n\016history_" + - "length\030\002 \001(\005H\000\210\001\001B\021\n\017_history_length\"\225\002\n" + - "\020ListTasksRequest\022\016\n\006tenant\030\t \001(\t\022\022\n\ncon" + - "text_id\030\001 \001(\t\022!\n\006status\030\002 \001(\0162\021.a2a.v1.T" + - "askState\022\026\n\tpage_size\030\003 \001(\005H\000\210\001\001\022\022\n\npage" + - "_token\030\004 \001(\t\022\033\n\016history_length\030\005 \001(\005H\001\210\001" + - "\001\022\032\n\022last_updated_after\030\006 \001(\003\022\036\n\021include" + - "_artifacts\030\007 \001(\010H\002\210\001\001B\014\n\n_page_sizeB\021\n\017_" + - "history_lengthB\024\n\022_include_artifacts\"\204\001\n" + - "\021ListTasksResponse\022 \n\005tasks\030\001 \003(\0132\014.a2a." + - "v1.TaskB\003\340A\002\022\034\n\017next_page_token\030\002 \001(\tB\003\340" + - "A\002\022\026\n\tpage_size\030\003 \001(\005B\003\340A\002\022\027\n\ntotal_size" + - "\030\004 \001(\005B\003\340A\002\"1\n\021CancelTaskRequest\022\016\n\006tena" + - "nt\030\002 \001(\t\022\014\n\004name\030\001 \001(\t\"D\n$GetTaskPushNot" + - "ificationConfigRequest\022\016\n\006tenant\030\002 \001(\t\022\014" + - "\n\004name\030\001 \001(\t\"G\n\'DeleteTaskPushNotificati" + - "onConfigRequest\022\016\n\006tenant\030\002 \001(\t\022\014\n\004name\030" + - "\001 \001(\t\"\234\001\n$SetTaskPushNotificationConfigR" + - "equest\022\016\n\006tenant\030\004 \001(\t\022\023\n\006parent\030\001 \001(\tB\003" + - "\340A\002\022\026\n\tconfig_id\030\002 \001(\tB\003\340A\002\0227\n\006config\030\003 " + - "\001(\0132\".a2a.v1.TaskPushNotificationConfigB" + - "\003\340A\002\"6\n\026SubscribeToTaskRequest\022\016\n\006tenant" + - "\030\002 \001(\t\022\014\n\004name\030\001 \001(\t\"n\n%ListTaskPushNoti" + - "ficationConfigRequest\022\016\n\006tenant\030\004 \001(\t\022\016\n" + - "\006parent\030\001 \001(\t\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage" + - "_token\030\003 \001(\t\"-\n\033GetExtendedAgentCardRequ" + - "est\022\016\n\006tenant\030\001 \001(\t\"g\n\023SendMessageRespon" + - "se\022\034\n\004task\030\001 \001(\0132\014.a2a.v1.TaskH\000\022\'\n\003msg\030" + - "\002 \001(\0132\017.a2a.v1.MessageH\000R\007messageB\t\n\007pay" + - "load\"\326\001\n\016StreamResponse\022\034\n\004task\030\001 \001(\0132\014." + - "a2a.v1.TaskH\000\022\'\n\003msg\030\002 \001(\0132\017.a2a.v1.Mess" + - "ageH\000R\007message\0226\n\rstatus_update\030\003 \001(\0132\035." + - "a2a.v1.TaskStatusUpdateEventH\000\022:\n\017artifa" + - "ct_update\030\004 \001(\0132\037.a2a.v1.TaskArtifactUpd" + - "ateEventH\000B\t\n\007payload\"v\n&ListTaskPushNot" + - "ificationConfigResponse\0223\n\007configs\030\001 \003(\013" + - "2\".a2a.v1.TaskPushNotificationConfig\022\027\n\017" + - "next_page_token\030\002 \001(\t*\372\001\n\tTaskState\022\032\n\026T" + - "ASK_STATE_UNSPECIFIED\020\000\022\030\n\024TASK_STATE_SU" + - "BMITTED\020\001\022\026\n\022TASK_STATE_WORKING\020\002\022\030\n\024TAS" + - "K_STATE_COMPLETED\020\003\022\025\n\021TASK_STATE_FAILED" + - "\020\004\022\030\n\024TASK_STATE_CANCELLED\020\005\022\035\n\031TASK_STA" + - "TE_INPUT_REQUIRED\020\006\022\027\n\023TASK_STATE_REJECT" + - "ED\020\007\022\034\n\030TASK_STATE_AUTH_REQUIRED\020\010*;\n\004Ro" + - "le\022\024\n\020ROLE_UNSPECIFIED\020\000\022\r\n\tROLE_USER\020\001\022" + - "\016\n\nROLE_AGENT\020\0022\276\016\n\nA2AService\022}\n\013SendMe" + - "ssage\022\032.a2a.v1.SendMessageRequest\032\033.a2a." + - "v1.SendMessageResponse\"5\202\323\344\223\002/\"\r/message" + - ":send:\001*Z\033\"\026/{tenant}/message:send:\001*\022\207\001" + - "\n\024SendStreamingMessage\022\032.a2a.v1.SendMess" + - "ageRequest\032\026.a2a.v1.StreamResponse\"9\202\323\344\223" + - "\0023\"\017/message:stream:\001*Z\035\"\030/{tenant}/mess" + - "age:stream:\001*0\001\022k\n\007GetTask\022\026.a2a.v1.GetT" + - "askRequest\032\014.a2a.v1.Task\":\332A\004name\202\323\344\223\002-\022" + - "\017/{name=tasks/*}Z\032\022\030/{tenant}/{name=task" + - "s/*}\022c\n\tListTasks\022\030.a2a.v1.ListTasksRequ" + - "est\032\031.a2a.v1.ListTasksResponse\"!\202\323\344\223\002\033\022\006" + - "/tasksZ\021\022\017/{tenant}/tasks\022~\n\nCancelTask\022" + - "\031.a2a.v1.CancelTaskRequest\032\014.a2a.v1.Task" + - "\"G\202\323\344\223\002A\"\026/{name=tasks/*}:cancel:\001*Z$\"\037/" + - "{tenant}/{name=tasks/*}:cancel:\001*\022\224\001\n\017Su" + - "bscribeToTask\022\036.a2a.v1.SubscribeToTaskRe" + - "quest\032\026.a2a.v1.StreamResponse\"G\202\323\344\223\002A\022\031/" + - "{name=tasks/*}:subscribeZ$\022\"/{tenant}/{n" + - "ame=tasks/*}:subscribe0\001\022\373\001\n\035SetTaskPush" + - "NotificationConfig\022,.a2a.v1.SetTaskPushN" + - "otificationConfigRequest\032\".a2a.v1.TaskPu" + - "shNotificationConfig\"\207\001\332A\rparent,config\202" + - "\323\344\223\002q\")/{parent=tasks/*/pushNotification" + - "Configs}:\006configZ<\"2/{tenant}/{parent=ta" + - "sks/*/pushNotificationConfigs}:\006config\022\341" + - "\001\n\035GetTaskPushNotificationConfig\022,.a2a.v" + - "1.GetTaskPushNotificationConfigRequest\032\"" + - ".a2a.v1.TaskPushNotificationConfig\"n\332A\004n" + - "ame\202\323\344\223\002a\022)/{name=tasks/*/pushNotificati" + - "onConfigs/*}Z4\0222/{tenant}/{name=tasks/*/" + - "pushNotificationConfigs/*}\022\361\001\n\036ListTaskP" + - "ushNotificationConfig\022-.a2a.v1.ListTaskP" + - "ushNotificationConfigRequest\032..a2a.v1.Li" + - "stTaskPushNotificationConfigResponse\"p\332A" + - "\006parent\202\323\344\223\002a\022)/{parent=tasks/*}/pushNot" + - "ificationConfigsZ4\0222/{tenant}/{parent=ta" + - "sks/*}/pushNotificationConfigs\022\211\001\n\024GetEx" + - "tendedAgentCard\022#.a2a.v1.GetExtendedAgen" + - "tCardRequest\032\021.a2a.v1.AgentCard\"9\202\323\344\223\0023\022" + - "\022/extendedAgentCardZ\035\022\033/{tenant}/extende" + - "dAgentCard\022\333\001\n DeleteTaskPushNotificatio" + - "nConfig\022/.a2a.v1.DeleteTaskPushNotificat" + - "ionConfigRequest\032\026.google.protobuf.Empty" + - "\"n\332A\004name\202\323\344\223\002a*)/{name=tasks/*/pushNoti" + - "ficationConfigs/*}Z4*2/{tenant}/{name=ta" + - "sks/*/pushNotificationConfigs/*}B7\n\013io.a" + - "2a.grpcB\003A2AP\001Z\030google.golang.org/a2a/v1" + - "\252\002\006A2a.V1b\006proto3" + "alue\030\002 \001(\t:\0028\001\"\326\001\n\023DeviceCodeOAuthFlow\022%" + + "\n\030device_authorization_url\030\001 \001(\tB\003\340A\002\022\026\n" + + "\ttoken_url\030\002 \001(\tB\003\340A\002\022\023\n\013refresh_url\030\003 \001" + + "(\t\022<\n\006scopes\030\004 \003(\0132\'.a2a.v1.DeviceCodeOA" + + "uthFlow.ScopesEntryB\003\340A\002\032-\n\013ScopesEntry\022" + + "\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\257\001\n\022Send" + + "MessageRequest\022\016\n\006tenant\030\004 \001(\t\022%\n\007messag" + + "e\030\001 \001(\0132\017.a2a.v1.MessageB\003\340A\002\0227\n\rconfigu" + + "ration\030\002 \001(\0132 .a2a.v1.SendMessageConfigu" + + "ration\022)\n\010metadata\030\003 \001(\0132\027.google.protob" + + "uf.Struct\"c\n\016GetTaskRequest\022\016\n\006tenant\030\003 " + + "\001(\t\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\033\n\016history_length" + + "\030\002 \001(\005H\000\210\001\001B\021\n\017_history_length\"\265\002\n\020ListT" + + "asksRequest\022\016\n\006tenant\030\t \001(\t\022\022\n\ncontext_i" + + "d\030\001 \001(\t\022!\n\006status\030\002 \001(\0162\021.a2a.v1.TaskSta" + + "te\022\026\n\tpage_size\030\003 \001(\005H\000\210\001\001\022\022\n\npage_token" + + "\030\004 \001(\t\022\033\n\016history_length\030\005 \001(\005H\001\210\001\001\022:\n\026s" + + "tatus_timestamp_after\030\006 \001(\0132\032.google.pro" + + "tobuf.Timestamp\022\036\n\021include_artifacts\030\007 \001" + + "(\010H\002\210\001\001B\014\n\n_page_sizeB\021\n\017_history_length" + + "B\024\n\022_include_artifacts\"\204\001\n\021ListTasksResp" + + "onse\022 \n\005tasks\030\001 \003(\0132\014.a2a.v1.TaskB\003\340A\002\022\034" + + "\n\017next_page_token\030\002 \001(\tB\003\340A\002\022\026\n\tpage_siz" + + "e\030\003 \001(\005B\003\340A\002\022\027\n\ntotal_size\030\004 \001(\005B\003\340A\002\"1\n" + + "\021CancelTaskRequest\022\016\n\006tenant\030\002 \001(\t\022\014\n\004na" + + "me\030\001 \001(\t\"D\n$GetTaskPushNotificationConfi" + + "gRequest\022\016\n\006tenant\030\002 \001(\t\022\014\n\004name\030\001 \001(\t\"G" + + "\n\'DeleteTaskPushNotificationConfigReques" + + "t\022\016\n\006tenant\030\002 \001(\t\022\014\n\004name\030\001 \001(\t\"\234\001\n$SetT" + + "askPushNotificationConfigRequest\022\016\n\006tena" + + "nt\030\004 \001(\t\022\023\n\006parent\030\001 \001(\tB\003\340A\002\022\026\n\tconfig_" + + "id\030\002 \001(\tB\003\340A\002\0227\n\006config\030\003 \001(\0132\".a2a.v1.T" + + "askPushNotificationConfigB\003\340A\002\"6\n\026Subscr" + + "ibeToTaskRequest\022\016\n\006tenant\030\002 \001(\t\022\014\n\004name" + + "\030\001 \001(\t\"n\n%ListTaskPushNotificationConfig" + + "Request\022\016\n\006tenant\030\004 \001(\t\022\016\n\006parent\030\001 \001(\t\022" + + "\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"-" + + "\n\033GetExtendedAgentCardRequest\022\016\n\006tenant\030" + + "\001 \001(\t\"b\n\023SendMessageResponse\022\034\n\004task\030\001 \001" + + "(\0132\014.a2a.v1.TaskH\000\022\"\n\007message\030\002 \001(\0132\017.a2" + + "a.v1.MessageH\000B\t\n\007payload\"\321\001\n\016StreamResp" + + "onse\022\034\n\004task\030\001 \001(\0132\014.a2a.v1.TaskH\000\022\"\n\007me" + + "ssage\030\002 \001(\0132\017.a2a.v1.MessageH\000\0226\n\rstatus" + + "_update\030\003 \001(\0132\035.a2a.v1.TaskStatusUpdateE" + + "ventH\000\022:\n\017artifact_update\030\004 \001(\0132\037.a2a.v1" + + ".TaskArtifactUpdateEventH\000B\t\n\007payload\"v\n" + + "&ListTaskPushNotificationConfigResponse\022" + + "3\n\007configs\030\001 \003(\0132\".a2a.v1.TaskPushNotifi" + + "cationConfig\022\027\n\017next_page_token\030\002 \001(\t*\372\001" + + "\n\tTaskState\022\032\n\026TASK_STATE_UNSPECIFIED\020\000\022" + + "\030\n\024TASK_STATE_SUBMITTED\020\001\022\026\n\022TASK_STATE_" + + "WORKING\020\002\022\030\n\024TASK_STATE_COMPLETED\020\003\022\025\n\021T" + + "ASK_STATE_FAILED\020\004\022\030\n\024TASK_STATE_CANCELL" + + "ED\020\005\022\035\n\031TASK_STATE_INPUT_REQUIRED\020\006\022\027\n\023T" + + "ASK_STATE_REJECTED\020\007\022\034\n\030TASK_STATE_AUTH_" + + "REQUIRED\020\010*;\n\004Role\022\024\n\020ROLE_UNSPECIFIED\020\000" + + "\022\r\n\tROLE_USER\020\001\022\016\n\nROLE_AGENT\020\0022\276\016\n\nA2AS" + + "ervice\022}\n\013SendMessage\022\032.a2a.v1.SendMessa" + + "geRequest\032\033.a2a.v1.SendMessageResponse\"5" + + "\202\323\344\223\002/\"\r/message:send:\001*Z\033\"\026/{tenant}/me" + + "ssage:send:\001*\022\207\001\n\024SendStreamingMessage\022\032" + + ".a2a.v1.SendMessageRequest\032\026.a2a.v1.Stre" + + "amResponse\"9\202\323\344\223\0023\"\017/message:stream:\001*Z\035" + + "\"\030/{tenant}/message:stream:\001*0\001\022k\n\007GetTa" + + "sk\022\026.a2a.v1.GetTaskRequest\032\014.a2a.v1.Task" + + "\":\332A\004name\202\323\344\223\002-\022\017/{name=tasks/*}Z\032\022\030/{te" + + "nant}/{name=tasks/*}\022c\n\tListTasks\022\030.a2a." + + "v1.ListTasksRequest\032\031.a2a.v1.ListTasksRe" + + "sponse\"!\202\323\344\223\002\033\022\006/tasksZ\021\022\017/{tenant}/task" + + "s\022~\n\nCancelTask\022\031.a2a.v1.CancelTaskReque" + + "st\032\014.a2a.v1.Task\"G\202\323\344\223\002A\"\026/{name=tasks/*" + + "}:cancel:\001*Z$\"\037/{tenant}/{name=tasks/*}:" + + "cancel:\001*\022\224\001\n\017SubscribeToTask\022\036.a2a.v1.S" + + "ubscribeToTaskRequest\032\026.a2a.v1.StreamRes" + + "ponse\"G\202\323\344\223\002A\022\031/{name=tasks/*}:subscribe" + + "Z$\022\"/{tenant}/{name=tasks/*}:subscribe0\001" + + "\022\373\001\n\035SetTaskPushNotificationConfig\022,.a2a" + + ".v1.SetTaskPushNotificationConfigRequest" + + "\032\".a2a.v1.TaskPushNotificationConfig\"\207\001\332" + + "A\rparent,config\202\323\344\223\002q\")/{parent=tasks/*/" + + "pushNotificationConfigs}:\006configZ<\"2/{te" + + "nant}/{parent=tasks/*/pushNotificationCo" + + "nfigs}:\006config\022\341\001\n\035GetTaskPushNotificati" + + "onConfig\022,.a2a.v1.GetTaskPushNotificatio" + + "nConfigRequest\032\".a2a.v1.TaskPushNotifica" + + "tionConfig\"n\332A\004name\202\323\344\223\002a\022)/{name=tasks/" + + "*/pushNotificationConfigs/*}Z4\0222/{tenant" + + "}/{name=tasks/*/pushNotificationConfigs/" + + "*}\022\361\001\n\036ListTaskPushNotificationConfig\022-." + + "a2a.v1.ListTaskPushNotificationConfigReq" + + "uest\032..a2a.v1.ListTaskPushNotificationCo" + + "nfigResponse\"p\332A\006parent\202\323\344\223\002a\022)/{parent=" + + "tasks/*}/pushNotificationConfigsZ4\0222/{te" + + "nant}/{parent=tasks/*}/pushNotificationC" + + "onfigs\022\211\001\n\024GetExtendedAgentCard\022#.a2a.v1" + + ".GetExtendedAgentCardRequest\032\021.a2a.v1.Ag" + + "entCard\"9\202\323\344\223\0023\022\022/extendedAgentCardZ\035\022\033/" + + "{tenant}/extendedAgentCard\022\333\001\n DeleteTas" + + "kPushNotificationConfig\022/.a2a.v1.DeleteT" + + "askPushNotificationConfigRequest\032\026.googl" + + "e.protobuf.Empty\"n\332A\004name\202\323\344\223\002a*)/{name=" + + "tasks/*/pushNotificationConfigs/*}Z4*2/{" + + "tenant}/{name=tasks/*/pushNotificationCo" + + "nfigs/*}B7\n\013io.a2a.grpcB\003A2AP\001Z\030google.g" + + "olang.org/a2a/v1\252\002\006A2a.V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor .internalBuildGeneratedFileFrom(descriptorData, @@ -639,7 +621,7 @@ public static void registerAllExtensions( internal_static_a2a_v1_AgentCard_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_AgentCard_descriptor, - new java.lang.String[] { "ProtocolVersion", "Name", "Description", "SupportedInterfaces", "Url", "PreferredTransport", "AdditionalInterfaces", "Provider", "Version", "DocumentationUrl", "Capabilities", "SecuritySchemes", "Security", "DefaultInputModes", "DefaultOutputModes", "Skills", "SupportsExtendedAgentCard", "Signatures", "IconUrl", }); + new java.lang.String[] { "ProtocolVersions", "Name", "Description", "SupportedInterfaces", "Provider", "Version", "DocumentationUrl", "Capabilities", "SecuritySchemes", "Security", "DefaultInputModes", "DefaultOutputModes", "Skills", "Signatures", "IconUrl", }); internal_static_a2a_v1_AgentCard_SecuritySchemesEntry_descriptor = internal_static_a2a_v1_AgentCard_descriptor.getNestedType(0); internal_static_a2a_v1_AgentCard_SecuritySchemesEntry_fieldAccessorTable = new @@ -657,7 +639,7 @@ public static void registerAllExtensions( internal_static_a2a_v1_AgentCapabilities_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_AgentCapabilities_descriptor, - new java.lang.String[] { "Streaming", "PushNotifications", "Extensions", "StateTransitionHistory", }); + new java.lang.String[] { "Streaming", "PushNotifications", "Extensions", "StateTransitionHistory", "ExtendedAgentCard", }); internal_static_a2a_v1_AgentExtension_descriptor = getDescriptor().getMessageType(16); internal_static_a2a_v1_AgentExtension_fieldAccessorTable = new @@ -741,13 +723,13 @@ public static void registerAllExtensions( internal_static_a2a_v1_OAuthFlows_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_OAuthFlows_descriptor, - new java.lang.String[] { "AuthorizationCode", "ClientCredentials", "Implicit", "Password", "Flow", }); + new java.lang.String[] { "AuthorizationCode", "ClientCredentials", "DeviceCode", "Flow", }); internal_static_a2a_v1_AuthorizationCodeOAuthFlow_descriptor = getDescriptor().getMessageType(29); internal_static_a2a_v1_AuthorizationCodeOAuthFlow_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_AuthorizationCodeOAuthFlow_descriptor, - new java.lang.String[] { "AuthorizationUrl", "TokenUrl", "RefreshUrl", "Scopes", }); + new java.lang.String[] { "AuthorizationUrl", "TokenUrl", "RefreshUrl", "Scopes", "PkceRequired", }); internal_static_a2a_v1_AuthorizationCodeOAuthFlow_ScopesEntry_descriptor = internal_static_a2a_v1_AuthorizationCodeOAuthFlow_descriptor.getNestedType(0); internal_static_a2a_v1_AuthorizationCodeOAuthFlow_ScopesEntry_fieldAccessorTable = new @@ -766,110 +748,98 @@ public static void registerAllExtensions( com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_ClientCredentialsOAuthFlow_ScopesEntry_descriptor, new java.lang.String[] { "Key", "Value", }); - internal_static_a2a_v1_ImplicitOAuthFlow_descriptor = + internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor = getDescriptor().getMessageType(31); - internal_static_a2a_v1_ImplicitOAuthFlow_fieldAccessorTable = new + internal_static_a2a_v1_DeviceCodeOAuthFlow_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_a2a_v1_ImplicitOAuthFlow_descriptor, - new java.lang.String[] { "AuthorizationUrl", "RefreshUrl", "Scopes", }); - internal_static_a2a_v1_ImplicitOAuthFlow_ScopesEntry_descriptor = - internal_static_a2a_v1_ImplicitOAuthFlow_descriptor.getNestedType(0); - internal_static_a2a_v1_ImplicitOAuthFlow_ScopesEntry_fieldAccessorTable = new + internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor, + new java.lang.String[] { "DeviceAuthorizationUrl", "TokenUrl", "RefreshUrl", "Scopes", }); + internal_static_a2a_v1_DeviceCodeOAuthFlow_ScopesEntry_descriptor = + internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor.getNestedType(0); + internal_static_a2a_v1_DeviceCodeOAuthFlow_ScopesEntry_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_a2a_v1_ImplicitOAuthFlow_ScopesEntry_descriptor, - new java.lang.String[] { "Key", "Value", }); - internal_static_a2a_v1_PasswordOAuthFlow_descriptor = - getDescriptor().getMessageType(32); - internal_static_a2a_v1_PasswordOAuthFlow_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_a2a_v1_PasswordOAuthFlow_descriptor, - new java.lang.String[] { "TokenUrl", "RefreshUrl", "Scopes", }); - internal_static_a2a_v1_PasswordOAuthFlow_ScopesEntry_descriptor = - internal_static_a2a_v1_PasswordOAuthFlow_descriptor.getNestedType(0); - internal_static_a2a_v1_PasswordOAuthFlow_ScopesEntry_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_a2a_v1_PasswordOAuthFlow_ScopesEntry_descriptor, + internal_static_a2a_v1_DeviceCodeOAuthFlow_ScopesEntry_descriptor, new java.lang.String[] { "Key", "Value", }); internal_static_a2a_v1_SendMessageRequest_descriptor = - getDescriptor().getMessageType(33); + getDescriptor().getMessageType(32); internal_static_a2a_v1_SendMessageRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_SendMessageRequest_descriptor, - new java.lang.String[] { "Tenant", "Request", "Configuration", "Metadata", }); + new java.lang.String[] { "Tenant", "Message", "Configuration", "Metadata", }); internal_static_a2a_v1_GetTaskRequest_descriptor = - getDescriptor().getMessageType(34); + getDescriptor().getMessageType(33); internal_static_a2a_v1_GetTaskRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_GetTaskRequest_descriptor, new java.lang.String[] { "Tenant", "Name", "HistoryLength", }); internal_static_a2a_v1_ListTasksRequest_descriptor = - getDescriptor().getMessageType(35); + getDescriptor().getMessageType(34); internal_static_a2a_v1_ListTasksRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_ListTasksRequest_descriptor, - new java.lang.String[] { "Tenant", "ContextId", "Status", "PageSize", "PageToken", "HistoryLength", "LastUpdatedAfter", "IncludeArtifacts", }); + new java.lang.String[] { "Tenant", "ContextId", "Status", "PageSize", "PageToken", "HistoryLength", "StatusTimestampAfter", "IncludeArtifacts", }); internal_static_a2a_v1_ListTasksResponse_descriptor = - getDescriptor().getMessageType(36); + getDescriptor().getMessageType(35); internal_static_a2a_v1_ListTasksResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_ListTasksResponse_descriptor, new java.lang.String[] { "Tasks", "NextPageToken", "PageSize", "TotalSize", }); internal_static_a2a_v1_CancelTaskRequest_descriptor = - getDescriptor().getMessageType(37); + getDescriptor().getMessageType(36); internal_static_a2a_v1_CancelTaskRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_CancelTaskRequest_descriptor, new java.lang.String[] { "Tenant", "Name", }); internal_static_a2a_v1_GetTaskPushNotificationConfigRequest_descriptor = - getDescriptor().getMessageType(38); + getDescriptor().getMessageType(37); internal_static_a2a_v1_GetTaskPushNotificationConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_GetTaskPushNotificationConfigRequest_descriptor, new java.lang.String[] { "Tenant", "Name", }); internal_static_a2a_v1_DeleteTaskPushNotificationConfigRequest_descriptor = - getDescriptor().getMessageType(39); + getDescriptor().getMessageType(38); internal_static_a2a_v1_DeleteTaskPushNotificationConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_DeleteTaskPushNotificationConfigRequest_descriptor, new java.lang.String[] { "Tenant", "Name", }); internal_static_a2a_v1_SetTaskPushNotificationConfigRequest_descriptor = - getDescriptor().getMessageType(40); + getDescriptor().getMessageType(39); internal_static_a2a_v1_SetTaskPushNotificationConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_SetTaskPushNotificationConfigRequest_descriptor, new java.lang.String[] { "Tenant", "Parent", "ConfigId", "Config", }); internal_static_a2a_v1_SubscribeToTaskRequest_descriptor = - getDescriptor().getMessageType(41); + getDescriptor().getMessageType(40); internal_static_a2a_v1_SubscribeToTaskRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_SubscribeToTaskRequest_descriptor, new java.lang.String[] { "Tenant", "Name", }); internal_static_a2a_v1_ListTaskPushNotificationConfigRequest_descriptor = - getDescriptor().getMessageType(42); + getDescriptor().getMessageType(41); internal_static_a2a_v1_ListTaskPushNotificationConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_ListTaskPushNotificationConfigRequest_descriptor, new java.lang.String[] { "Tenant", "Parent", "PageSize", "PageToken", }); internal_static_a2a_v1_GetExtendedAgentCardRequest_descriptor = - getDescriptor().getMessageType(43); + getDescriptor().getMessageType(42); internal_static_a2a_v1_GetExtendedAgentCardRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_GetExtendedAgentCardRequest_descriptor, new java.lang.String[] { "Tenant", }); internal_static_a2a_v1_SendMessageResponse_descriptor = - getDescriptor().getMessageType(44); + getDescriptor().getMessageType(43); internal_static_a2a_v1_SendMessageResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_SendMessageResponse_descriptor, - new java.lang.String[] { "Task", "Msg", "Payload", }); + new java.lang.String[] { "Task", "Message", "Payload", }); internal_static_a2a_v1_StreamResponse_descriptor = - getDescriptor().getMessageType(45); + getDescriptor().getMessageType(44); internal_static_a2a_v1_StreamResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_StreamResponse_descriptor, - new java.lang.String[] { "Task", "Msg", "StatusUpdate", "ArtifactUpdate", "Payload", }); + new java.lang.String[] { "Task", "Message", "StatusUpdate", "ArtifactUpdate", "Payload", }); internal_static_a2a_v1_ListTaskPushNotificationConfigResponse_descriptor = - getDescriptor().getMessageType(46); + getDescriptor().getMessageType(45); internal_static_a2a_v1_ListTaskPushNotificationConfigResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_a2a_v1_ListTaskPushNotificationConfigResponse_descriptor, diff --git a/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilities.java b/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilities.java index 84ef70448..2e6c44ab8 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilities.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilities.java @@ -192,6 +192,33 @@ public boolean getStateTransitionHistory() { return stateTransitionHistory_; } + public static final int EXTENDED_AGENT_CARD_FIELD_NUMBER = 5; + private boolean extendedAgentCard_ = false; + /** + *
    +   * Indicates if the agent supports providing an extended agent card when authenticated.
    +   * 
    + * + * optional bool extended_agent_card = 5; + * @return Whether the extendedAgentCard field is set. + */ + @java.lang.Override + public boolean hasExtendedAgentCard() { + return ((bitField0_ & 0x00000008) != 0); + } + /** + *
    +   * Indicates if the agent supports providing an extended agent card when authenticated.
    +   * 
    + * + * optional bool extended_agent_card = 5; + * @return The extendedAgentCard. + */ + @java.lang.Override + public boolean getExtendedAgentCard() { + return extendedAgentCard_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { @@ -218,6 +245,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) if (((bitField0_ & 0x00000004) != 0)) { output.writeBool(4, stateTransitionHistory_); } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeBool(5, extendedAgentCard_); + } getUnknownFields().writeTo(output); } @@ -243,6 +273,10 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream .computeBoolSize(4, stateTransitionHistory_); } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream + .computeBoolSize(5, extendedAgentCard_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -275,6 +309,11 @@ public boolean equals(final java.lang.Object obj) { if (getStateTransitionHistory() != other.getStateTransitionHistory()) return false; } + if (hasExtendedAgentCard() != other.hasExtendedAgentCard()) return false; + if (hasExtendedAgentCard()) { + if (getExtendedAgentCard() + != other.getExtendedAgentCard()) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -305,6 +344,11 @@ public int hashCode() { hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( getStateTransitionHistory()); } + if (hasExtendedAgentCard()) { + hash = (37 * hash) + EXTENDED_AGENT_CARD_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( + getExtendedAgentCard()); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -451,6 +495,7 @@ public Builder clear() { } bitField0_ = (bitField0_ & ~0x00000004); stateTransitionHistory_ = false; + extendedAgentCard_ = false; return this; } @@ -510,6 +555,10 @@ private void buildPartial0(io.a2a.grpc.AgentCapabilities result) { result.stateTransitionHistory_ = stateTransitionHistory_; to_bitField0_ |= 0x00000004; } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.extendedAgentCard_ = extendedAgentCard_; + to_bitField0_ |= 0x00000008; + } result.bitField0_ |= to_bitField0_; } @@ -560,6 +609,9 @@ public Builder mergeFrom(io.a2a.grpc.AgentCapabilities other) { if (other.hasStateTransitionHistory()) { setStateTransitionHistory(other.getStateTransitionHistory()); } + if (other.hasExtendedAgentCard()) { + setExtendedAgentCard(other.getExtendedAgentCard()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -614,6 +666,11 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 32 + case 40: { + extendedAgentCard_ = input.readBool(); + bitField0_ |= 0x00000010; + break; + } // case 40 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag @@ -1111,6 +1168,62 @@ public Builder clearStateTransitionHistory() { return this; } + private boolean extendedAgentCard_ ; + /** + *
    +     * Indicates if the agent supports providing an extended agent card when authenticated.
    +     * 
    + * + * optional bool extended_agent_card = 5; + * @return Whether the extendedAgentCard field is set. + */ + @java.lang.Override + public boolean hasExtendedAgentCard() { + return ((bitField0_ & 0x00000010) != 0); + } + /** + *
    +     * Indicates if the agent supports providing an extended agent card when authenticated.
    +     * 
    + * + * optional bool extended_agent_card = 5; + * @return The extendedAgentCard. + */ + @java.lang.Override + public boolean getExtendedAgentCard() { + return extendedAgentCard_; + } + /** + *
    +     * Indicates if the agent supports providing an extended agent card when authenticated.
    +     * 
    + * + * optional bool extended_agent_card = 5; + * @param value The extendedAgentCard to set. + * @return This builder for chaining. + */ + public Builder setExtendedAgentCard(boolean value) { + + extendedAgentCard_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + /** + *
    +     * Indicates if the agent supports providing an extended agent card when authenticated.
    +     * 
    + * + * optional bool extended_agent_card = 5; + * @return This builder for chaining. + */ + public Builder clearExtendedAgentCard() { + bitField0_ = (bitField0_ & ~0x00000010); + extendedAgentCard_ = false; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:a2a.v1.AgentCapabilities) } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilitiesOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilitiesOrBuilder.java index df5d9277c..b084db7ee 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilitiesOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/AgentCapabilitiesOrBuilder.java @@ -110,4 +110,23 @@ io.a2a.grpc.AgentExtensionOrBuilder getExtensionsOrBuilder( * @return The stateTransitionHistory. */ boolean getStateTransitionHistory(); + + /** + *
    +   * Indicates if the agent supports providing an extended agent card when authenticated.
    +   * 
    + * + * optional bool extended_agent_card = 5; + * @return Whether the extendedAgentCard field is set. + */ + boolean hasExtendedAgentCard(); + /** + *
    +   * Indicates if the agent supports providing an extended agent card when authenticated.
    +   * 
    + * + * optional bool extended_agent_card = 5; + * @return The extendedAgentCard. + */ + boolean getExtendedAgentCard(); } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/AgentCard.java b/spec-grpc/src/main/java/io/a2a/grpc/AgentCard.java index b352e84f5..5111e4f12 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/AgentCard.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/AgentCard.java @@ -36,13 +36,11 @@ private AgentCard(com.google.protobuf.GeneratedMessage.Builder builder) { super(builder); } private AgentCard() { - protocolVersion_ = ""; + protocolVersions_ = + com.google.protobuf.LazyStringArrayList.emptyList(); name_ = ""; description_ = ""; supportedInterfaces_ = java.util.Collections.emptyList(); - url_ = ""; - preferredTransport_ = ""; - additionalInterfaces_ = java.util.Collections.emptyList(); version_ = ""; documentationUrl_ = ""; security_ = java.util.Collections.emptyList(); @@ -81,66 +79,69 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl } private int bitField0_; - public static final int PROTOCOL_VERSION_FIELD_NUMBER = 16; + public static final int PROTOCOL_VERSIONS_FIELD_NUMBER = 16; @SuppressWarnings("serial") - private volatile java.lang.Object protocolVersion_ = ""; + private com.google.protobuf.LazyStringArrayList protocolVersions_ = + com.google.protobuf.LazyStringArrayList.emptyList(); /** *
    -   * The version of the A2A protocol this agent supports.
    -   * Default: "1.0"
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
        * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return Whether the protocolVersion field is set. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return A list containing the protocolVersions. */ - @java.lang.Override - public boolean hasProtocolVersion() { - return ((bitField0_ & 0x00000001) != 0); + public com.google.protobuf.ProtocolStringList + getProtocolVersionsList() { + return protocolVersions_; } /** *
    -   * The version of the A2A protocol this agent supports.
    -   * Default: "1.0"
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
        * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return The protocolVersion. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return The count of protocolVersions. */ - @java.lang.Override - public java.lang.String getProtocolVersion() { - java.lang.Object ref = protocolVersion_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - protocolVersion_ = s; - return s; - } + public int getProtocolVersionsCount() { + return protocolVersions_.size(); } /** *
    -   * The version of the A2A protocol this agent supports.
    -   * Default: "1.0"
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
        * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for protocolVersion. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index of the element to return. + * @return The protocolVersions at the given index. + */ + public java.lang.String getProtocolVersions(int index) { + return protocolVersions_.get(index); + } + /** + *
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
    +   * 
    + * + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index of the value to return. + * @return The bytes of the protocolVersions at the given index. */ - @java.lang.Override public com.google.protobuf.ByteString - getProtocolVersionBytes() { - java.lang.Object ref = protocolVersion_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - protocolVersion_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } + getProtocolVersionsBytes(int index) { + return protocolVersions_.getByteString(index); } public static final int NAME_FIELD_NUMBER = 1; @@ -251,7 +252,7 @@ public java.lang.String getDescription() { * Ordered list of supported interfaces. First entry is preferred. * * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public java.util.List getSupportedInterfacesList() { @@ -262,7 +263,7 @@ public java.util.List getSupportedInterfacesList() { * Ordered list of supported interfaces. First entry is preferred. * * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public java.util.List @@ -274,7 +275,7 @@ public java.util.List getSupportedInterfacesList() { * Ordered list of supported interfaces. First entry is preferred. * * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public int getSupportedInterfacesCount() { @@ -285,7 +286,7 @@ public int getSupportedInterfacesCount() { * Ordered list of supported interfaces. First entry is preferred. * * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public io.a2a.grpc.AgentInterface getSupportedInterfaces(int index) { @@ -296,7 +297,7 @@ public io.a2a.grpc.AgentInterface getSupportedInterfaces(int index) { * Ordered list of supported interfaces. First entry is preferred. * * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public io.a2a.grpc.AgentInterfaceOrBuilder getSupportedInterfacesOrBuilder( @@ -304,197 +305,6 @@ public io.a2a.grpc.AgentInterfaceOrBuilder getSupportedInterfacesOrBuilder( return supportedInterfaces_.get(index); } - public static final int URL_FIELD_NUMBER = 3; - @SuppressWarnings("serial") - private volatile java.lang.Object url_ = ""; - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return Whether the url field is set. - */ - @java.lang.Override - @java.lang.Deprecated public boolean hasUrl() { - return ((bitField0_ & 0x00000002) != 0); - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return The url. - */ - @java.lang.Override - @java.lang.Deprecated public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return The bytes for url. - */ - @java.lang.Override - @java.lang.Deprecated public com.google.protobuf.ByteString - getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PREFERRED_TRANSPORT_FIELD_NUMBER = 14; - @SuppressWarnings("serial") - private volatile java.lang.Object preferredTransport_ = ""; - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return Whether the preferredTransport field is set. - */ - @java.lang.Override - @java.lang.Deprecated public boolean hasPreferredTransport() { - return ((bitField0_ & 0x00000004) != 0); - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return The preferredTransport. - */ - @java.lang.Override - @java.lang.Deprecated public java.lang.String getPreferredTransport() { - java.lang.Object ref = preferredTransport_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - preferredTransport_ = s; - return s; - } - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return The bytes for preferredTransport. - */ - @java.lang.Override - @java.lang.Deprecated public com.google.protobuf.ByteString - getPreferredTransportBytes() { - java.lang.Object ref = preferredTransport_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - preferredTransport_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ADDITIONAL_INTERFACES_FIELD_NUMBER = 15; - @SuppressWarnings("serial") - private java.util.List additionalInterfaces_; - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Override - @java.lang.Deprecated public java.util.List getAdditionalInterfacesList() { - return additionalInterfaces_; - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Override - @java.lang.Deprecated public java.util.List - getAdditionalInterfacesOrBuilderList() { - return additionalInterfaces_; - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Override - @java.lang.Deprecated public int getAdditionalInterfacesCount() { - return additionalInterfaces_.size(); - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Override - @java.lang.Deprecated public io.a2a.grpc.AgentInterface getAdditionalInterfaces(int index) { - return additionalInterfaces_.get(index); - } - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Override - @java.lang.Deprecated public io.a2a.grpc.AgentInterfaceOrBuilder getAdditionalInterfacesOrBuilder( - int index) { - return additionalInterfaces_.get(index); - } - public static final int PROVIDER_FIELD_NUMBER = 4; private io.a2a.grpc.AgentProvider provider_; /** @@ -507,7 +317,7 @@ public io.a2a.grpc.AgentInterfaceOrBuilder getSupportedInterfacesOrBuilder( */ @java.lang.Override public boolean hasProvider() { - return ((bitField0_ & 0x00000008) != 0); + return ((bitField0_ & 0x00000001) != 0); } /** *
    @@ -595,7 +405,7 @@ public java.lang.String getVersion() {
        */
       @java.lang.Override
       public boolean hasDocumentationUrl() {
    -    return ((bitField0_ & 0x00000010) != 0);
    +    return ((bitField0_ & 0x00000002) != 0);
       }
       /**
        * 
    @@ -653,7 +463,7 @@ public java.lang.String getDocumentationUrl() {
        */
       @java.lang.Override
       public boolean hasCapabilities() {
    -    return ((bitField0_ & 0x00000020) != 0);
    +    return ((bitField0_ & 0x00000004) != 0);
       }
       /**
        * 
    @@ -1025,33 +835,6 @@ public io.a2a.grpc.AgentSkillOrBuilder getSkillsOrBuilder(
         return skills_.get(index);
       }
     
    -  public static final int SUPPORTS_EXTENDED_AGENT_CARD_FIELD_NUMBER = 13;
    -  private boolean supportsExtendedAgentCard_ = false;
    -  /**
    -   * 
    -   * Whether the agent supports providing an extended agent card when authenticated.
    -   * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return Whether the supportsExtendedAgentCard field is set. - */ - @java.lang.Override - public boolean hasSupportsExtendedAgentCard() { - return ((bitField0_ & 0x00000040) != 0); - } - /** - *
    -   * Whether the agent supports providing an extended agent card when authenticated.
    -   * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return The supportsExtendedAgentCard. - */ - @java.lang.Override - public boolean getSupportsExtendedAgentCard() { - return supportsExtendedAgentCard_; - } - public static final int SIGNATURES_FIELD_NUMBER = 17; @SuppressWarnings("serial") private java.util.List signatures_; @@ -1126,7 +909,7 @@ public io.a2a.grpc.AgentCardSignatureOrBuilder getSignaturesOrBuilder( */ @java.lang.Override public boolean hasIconUrl() { - return ((bitField0_ & 0x00000080) != 0); + return ((bitField0_ & 0x00000008) != 0); } /** *
    @@ -1192,19 +975,16 @@ public void writeTo(com.google.protobuf.CodedOutputStream output)
         if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) {
           com.google.protobuf.GeneratedMessage.writeString(output, 2, description_);
         }
    -    if (((bitField0_ & 0x00000002) != 0)) {
    -      com.google.protobuf.GeneratedMessage.writeString(output, 3, url_);
    -    }
    -    if (((bitField0_ & 0x00000008) != 0)) {
    +    if (((bitField0_ & 0x00000001) != 0)) {
           output.writeMessage(4, getProvider());
         }
         if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) {
           com.google.protobuf.GeneratedMessage.writeString(output, 5, version_);
         }
    -    if (((bitField0_ & 0x00000010) != 0)) {
    +    if (((bitField0_ & 0x00000002) != 0)) {
           com.google.protobuf.GeneratedMessage.writeString(output, 6, documentationUrl_);
         }
    -    if (((bitField0_ & 0x00000020) != 0)) {
    +    if (((bitField0_ & 0x00000004) != 0)) {
           output.writeMessage(7, getCapabilities());
         }
         com.google.protobuf.GeneratedMessage
    @@ -1225,22 +1005,13 @@ public void writeTo(com.google.protobuf.CodedOutputStream output)
         for (int i = 0; i < skills_.size(); i++) {
           output.writeMessage(12, skills_.get(i));
         }
    -    if (((bitField0_ & 0x00000040) != 0)) {
    -      output.writeBool(13, supportsExtendedAgentCard_);
    -    }
    -    if (((bitField0_ & 0x00000004) != 0)) {
    -      com.google.protobuf.GeneratedMessage.writeString(output, 14, preferredTransport_);
    -    }
    -    for (int i = 0; i < additionalInterfaces_.size(); i++) {
    -      output.writeMessage(15, additionalInterfaces_.get(i));
    -    }
    -    if (((bitField0_ & 0x00000001) != 0)) {
    -      com.google.protobuf.GeneratedMessage.writeString(output, 16, protocolVersion_);
    +    for (int i = 0; i < protocolVersions_.size(); i++) {
    +      com.google.protobuf.GeneratedMessage.writeString(output, 16, protocolVersions_.getRaw(i));
         }
         for (int i = 0; i < signatures_.size(); i++) {
           output.writeMessage(17, signatures_.get(i));
         }
    -    if (((bitField0_ & 0x00000080) != 0)) {
    +    if (((bitField0_ & 0x00000008) != 0)) {
           com.google.protobuf.GeneratedMessage.writeString(output, 18, iconUrl_);
         }
         for (int i = 0; i < supportedInterfaces_.size(); i++) {
    @@ -1261,20 +1032,17 @@ public int getSerializedSize() {
         if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) {
           size += com.google.protobuf.GeneratedMessage.computeStringSize(2, description_);
         }
    -    if (((bitField0_ & 0x00000002) != 0)) {
    -      size += com.google.protobuf.GeneratedMessage.computeStringSize(3, url_);
    -    }
    -    if (((bitField0_ & 0x00000008) != 0)) {
    +    if (((bitField0_ & 0x00000001) != 0)) {
           size += com.google.protobuf.CodedOutputStream
             .computeMessageSize(4, getProvider());
         }
         if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) {
           size += com.google.protobuf.GeneratedMessage.computeStringSize(5, version_);
         }
    -    if (((bitField0_ & 0x00000010) != 0)) {
    +    if (((bitField0_ & 0x00000002) != 0)) {
           size += com.google.protobuf.GeneratedMessage.computeStringSize(6, documentationUrl_);
         }
    -    if (((bitField0_ & 0x00000020) != 0)) {
    +    if (((bitField0_ & 0x00000004) != 0)) {
           size += com.google.protobuf.CodedOutputStream
             .computeMessageSize(7, getCapabilities());
         }
    @@ -1312,25 +1080,19 @@ public int getSerializedSize() {
           size += com.google.protobuf.CodedOutputStream
             .computeMessageSize(12, skills_.get(i));
         }
    -    if (((bitField0_ & 0x00000040) != 0)) {
    -      size += com.google.protobuf.CodedOutputStream
    -        .computeBoolSize(13, supportsExtendedAgentCard_);
    -    }
    -    if (((bitField0_ & 0x00000004) != 0)) {
    -      size += com.google.protobuf.GeneratedMessage.computeStringSize(14, preferredTransport_);
    -    }
    -    for (int i = 0; i < additionalInterfaces_.size(); i++) {
    -      size += com.google.protobuf.CodedOutputStream
    -        .computeMessageSize(15, additionalInterfaces_.get(i));
    -    }
    -    if (((bitField0_ & 0x00000001) != 0)) {
    -      size += com.google.protobuf.GeneratedMessage.computeStringSize(16, protocolVersion_);
    +    {
    +      int dataSize = 0;
    +      for (int i = 0; i < protocolVersions_.size(); i++) {
    +        dataSize += computeStringSizeNoTag(protocolVersions_.getRaw(i));
    +      }
    +      size += dataSize;
    +      size += 2 * getProtocolVersionsList().size();
         }
         for (int i = 0; i < signatures_.size(); i++) {
           size += com.google.protobuf.CodedOutputStream
             .computeMessageSize(17, signatures_.get(i));
         }
    -    if (((bitField0_ & 0x00000080) != 0)) {
    +    if (((bitField0_ & 0x00000008) != 0)) {
           size += com.google.protobuf.GeneratedMessage.computeStringSize(18, iconUrl_);
         }
         for (int i = 0; i < supportedInterfaces_.size(); i++) {
    @@ -1352,29 +1114,14 @@ public boolean equals(final java.lang.Object obj) {
         }
         io.a2a.grpc.AgentCard other = (io.a2a.grpc.AgentCard) obj;
     
    -    if (hasProtocolVersion() != other.hasProtocolVersion()) return false;
    -    if (hasProtocolVersion()) {
    -      if (!getProtocolVersion()
    -          .equals(other.getProtocolVersion())) return false;
    -    }
    +    if (!getProtocolVersionsList()
    +        .equals(other.getProtocolVersionsList())) return false;
         if (!getName()
             .equals(other.getName())) return false;
         if (!getDescription()
             .equals(other.getDescription())) return false;
         if (!getSupportedInterfacesList()
             .equals(other.getSupportedInterfacesList())) return false;
    -    if (hasUrl() != other.hasUrl()) return false;
    -    if (hasUrl()) {
    -      if (!getUrl()
    -          .equals(other.getUrl())) return false;
    -    }
    -    if (hasPreferredTransport() != other.hasPreferredTransport()) return false;
    -    if (hasPreferredTransport()) {
    -      if (!getPreferredTransport()
    -          .equals(other.getPreferredTransport())) return false;
    -    }
    -    if (!getAdditionalInterfacesList()
    -        .equals(other.getAdditionalInterfacesList())) return false;
         if (hasProvider() != other.hasProvider()) return false;
         if (hasProvider()) {
           if (!getProvider()
    @@ -1402,11 +1149,6 @@ public boolean equals(final java.lang.Object obj) {
             .equals(other.getDefaultOutputModesList())) return false;
         if (!getSkillsList()
             .equals(other.getSkillsList())) return false;
    -    if (hasSupportsExtendedAgentCard() != other.hasSupportsExtendedAgentCard()) return false;
    -    if (hasSupportsExtendedAgentCard()) {
    -      if (getSupportsExtendedAgentCard()
    -          != other.getSupportsExtendedAgentCard()) return false;
    -    }
         if (!getSignaturesList()
             .equals(other.getSignaturesList())) return false;
         if (hasIconUrl() != other.hasIconUrl()) return false;
    @@ -1425,9 +1167,9 @@ public int hashCode() {
         }
         int hash = 41;
         hash = (19 * hash) + getDescriptor().hashCode();
    -    if (hasProtocolVersion()) {
    -      hash = (37 * hash) + PROTOCOL_VERSION_FIELD_NUMBER;
    -      hash = (53 * hash) + getProtocolVersion().hashCode();
    +    if (getProtocolVersionsCount() > 0) {
    +      hash = (37 * hash) + PROTOCOL_VERSIONS_FIELD_NUMBER;
    +      hash = (53 * hash) + getProtocolVersionsList().hashCode();
         }
         hash = (37 * hash) + NAME_FIELD_NUMBER;
         hash = (53 * hash) + getName().hashCode();
    @@ -1437,18 +1179,6 @@ public int hashCode() {
           hash = (37 * hash) + SUPPORTED_INTERFACES_FIELD_NUMBER;
           hash = (53 * hash) + getSupportedInterfacesList().hashCode();
         }
    -    if (hasUrl()) {
    -      hash = (37 * hash) + URL_FIELD_NUMBER;
    -      hash = (53 * hash) + getUrl().hashCode();
    -    }
    -    if (hasPreferredTransport()) {
    -      hash = (37 * hash) + PREFERRED_TRANSPORT_FIELD_NUMBER;
    -      hash = (53 * hash) + getPreferredTransport().hashCode();
    -    }
    -    if (getAdditionalInterfacesCount() > 0) {
    -      hash = (37 * hash) + ADDITIONAL_INTERFACES_FIELD_NUMBER;
    -      hash = (53 * hash) + getAdditionalInterfacesList().hashCode();
    -    }
         if (hasProvider()) {
           hash = (37 * hash) + PROVIDER_FIELD_NUMBER;
           hash = (53 * hash) + getProvider().hashCode();
    @@ -1483,11 +1213,6 @@ public int hashCode() {
           hash = (37 * hash) + SKILLS_FIELD_NUMBER;
           hash = (53 * hash) + getSkillsList().hashCode();
         }
    -    if (hasSupportsExtendedAgentCard()) {
    -      hash = (37 * hash) + SUPPORTS_EXTENDED_AGENT_CARD_FIELD_NUMBER;
    -      hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
    -          getSupportsExtendedAgentCard());
    -    }
         if (getSignaturesCount() > 0) {
           hash = (37 * hash) + SIGNATURES_FIELD_NUMBER;
           hash = (53 * hash) + getSignaturesList().hashCode();
    @@ -1657,7 +1382,6 @@ private void maybeForceBuilderInitialization() {
           if (com.google.protobuf.GeneratedMessage
                   .alwaysUseFieldBuilders) {
             internalGetSupportedInterfacesFieldBuilder();
    -        internalGetAdditionalInterfacesFieldBuilder();
             internalGetProviderFieldBuilder();
             internalGetCapabilitiesFieldBuilder();
             internalGetSecurityFieldBuilder();
    @@ -1669,7 +1393,8 @@ private void maybeForceBuilderInitialization() {
         public Builder clear() {
           super.clear();
           bitField0_ = 0;
    -      protocolVersion_ = "";
    +      protocolVersions_ =
    +          com.google.protobuf.LazyStringArrayList.emptyList();
           name_ = "";
           description_ = "";
           if (supportedInterfacesBuilder_ == null) {
    @@ -1679,15 +1404,6 @@ public Builder clear() {
             supportedInterfacesBuilder_.clear();
           }
           bitField0_ = (bitField0_ & ~0x00000008);
    -      url_ = "";
    -      preferredTransport_ = "";
    -      if (additionalInterfacesBuilder_ == null) {
    -        additionalInterfaces_ = java.util.Collections.emptyList();
    -      } else {
    -        additionalInterfaces_ = null;
    -        additionalInterfacesBuilder_.clear();
    -      }
    -      bitField0_ = (bitField0_ & ~0x00000040);
           provider_ = null;
           if (providerBuilder_ != null) {
             providerBuilder_.dispose();
    @@ -1707,7 +1423,7 @@ public Builder clear() {
             security_ = null;
             securityBuilder_.clear();
           }
    -      bitField0_ = (bitField0_ & ~0x00001000);
    +      bitField0_ = (bitField0_ & ~0x00000200);
           defaultInputModes_ =
               com.google.protobuf.LazyStringArrayList.emptyList();
           defaultOutputModes_ =
    @@ -1718,15 +1434,14 @@ public Builder clear() {
             skills_ = null;
             skillsBuilder_.clear();
           }
    -      bitField0_ = (bitField0_ & ~0x00008000);
    -      supportsExtendedAgentCard_ = false;
    +      bitField0_ = (bitField0_ & ~0x00001000);
           if (signaturesBuilder_ == null) {
             signatures_ = java.util.Collections.emptyList();
           } else {
             signatures_ = null;
             signaturesBuilder_.clear();
           }
    -      bitField0_ = (bitField0_ & ~0x00020000);
    +      bitField0_ = (bitField0_ & ~0x00002000);
           iconUrl_ = "";
           return this;
         }
    @@ -1770,37 +1485,28 @@ private void buildPartialRepeatedFields(io.a2a.grpc.AgentCard result) {
           } else {
             result.supportedInterfaces_ = supportedInterfacesBuilder_.build();
           }
    -      if (additionalInterfacesBuilder_ == null) {
    -        if (((bitField0_ & 0x00000040) != 0)) {
    -          additionalInterfaces_ = java.util.Collections.unmodifiableList(additionalInterfaces_);
    -          bitField0_ = (bitField0_ & ~0x00000040);
    -        }
    -        result.additionalInterfaces_ = additionalInterfaces_;
    -      } else {
    -        result.additionalInterfaces_ = additionalInterfacesBuilder_.build();
    -      }
           if (securityBuilder_ == null) {
    -        if (((bitField0_ & 0x00001000) != 0)) {
    +        if (((bitField0_ & 0x00000200) != 0)) {
               security_ = java.util.Collections.unmodifiableList(security_);
    -          bitField0_ = (bitField0_ & ~0x00001000);
    +          bitField0_ = (bitField0_ & ~0x00000200);
             }
             result.security_ = security_;
           } else {
             result.security_ = securityBuilder_.build();
           }
           if (skillsBuilder_ == null) {
    -        if (((bitField0_ & 0x00008000) != 0)) {
    +        if (((bitField0_ & 0x00001000) != 0)) {
               skills_ = java.util.Collections.unmodifiableList(skills_);
    -          bitField0_ = (bitField0_ & ~0x00008000);
    +          bitField0_ = (bitField0_ & ~0x00001000);
             }
             result.skills_ = skills_;
           } else {
             result.skills_ = skillsBuilder_.build();
           }
           if (signaturesBuilder_ == null) {
    -        if (((bitField0_ & 0x00020000) != 0)) {
    +        if (((bitField0_ & 0x00002000) != 0)) {
               signatures_ = java.util.Collections.unmodifiableList(signatures_);
    -          bitField0_ = (bitField0_ & ~0x00020000);
    +          bitField0_ = (bitField0_ & ~0x00002000);
             }
             result.signatures_ = signatures_;
           } else {
    @@ -1810,10 +1516,9 @@ private void buildPartialRepeatedFields(io.a2a.grpc.AgentCard result) {
     
         private void buildPartial0(io.a2a.grpc.AgentCard result) {
           int from_bitField0_ = bitField0_;
    -      int to_bitField0_ = 0;
           if (((from_bitField0_ & 0x00000001) != 0)) {
    -        result.protocolVersion_ = protocolVersion_;
    -        to_bitField0_ |= 0x00000001;
    +        protocolVersions_.makeImmutable();
    +        result.protocolVersions_ = protocolVersions_;
           }
           if (((from_bitField0_ & 0x00000002) != 0)) {
             result.name_ = name_;
    @@ -1821,51 +1526,40 @@ private void buildPartial0(io.a2a.grpc.AgentCard result) {
           if (((from_bitField0_ & 0x00000004) != 0)) {
             result.description_ = description_;
           }
    +      int to_bitField0_ = 0;
           if (((from_bitField0_ & 0x00000010) != 0)) {
    -        result.url_ = url_;
    -        to_bitField0_ |= 0x00000002;
    -      }
    -      if (((from_bitField0_ & 0x00000020) != 0)) {
    -        result.preferredTransport_ = preferredTransport_;
    -        to_bitField0_ |= 0x00000004;
    -      }
    -      if (((from_bitField0_ & 0x00000080) != 0)) {
             result.provider_ = providerBuilder_ == null
                 ? provider_
                 : providerBuilder_.build();
    -        to_bitField0_ |= 0x00000008;
    +        to_bitField0_ |= 0x00000001;
           }
    -      if (((from_bitField0_ & 0x00000100) != 0)) {
    +      if (((from_bitField0_ & 0x00000020) != 0)) {
             result.version_ = version_;
           }
    -      if (((from_bitField0_ & 0x00000200) != 0)) {
    +      if (((from_bitField0_ & 0x00000040) != 0)) {
             result.documentationUrl_ = documentationUrl_;
    -        to_bitField0_ |= 0x00000010;
    +        to_bitField0_ |= 0x00000002;
           }
    -      if (((from_bitField0_ & 0x00000400) != 0)) {
    +      if (((from_bitField0_ & 0x00000080) != 0)) {
             result.capabilities_ = capabilitiesBuilder_ == null
                 ? capabilities_
                 : capabilitiesBuilder_.build();
    -        to_bitField0_ |= 0x00000020;
    +        to_bitField0_ |= 0x00000004;
           }
    -      if (((from_bitField0_ & 0x00000800) != 0)) {
    +      if (((from_bitField0_ & 0x00000100) != 0)) {
             result.securitySchemes_ = internalGetSecuritySchemes().build(SecuritySchemesDefaultEntryHolder.defaultEntry);
           }
    -      if (((from_bitField0_ & 0x00002000) != 0)) {
    +      if (((from_bitField0_ & 0x00000400) != 0)) {
             defaultInputModes_.makeImmutable();
             result.defaultInputModes_ = defaultInputModes_;
           }
    -      if (((from_bitField0_ & 0x00004000) != 0)) {
    +      if (((from_bitField0_ & 0x00000800) != 0)) {
             defaultOutputModes_.makeImmutable();
             result.defaultOutputModes_ = defaultOutputModes_;
           }
    -      if (((from_bitField0_ & 0x00010000) != 0)) {
    -        result.supportsExtendedAgentCard_ = supportsExtendedAgentCard_;
    -        to_bitField0_ |= 0x00000040;
    -      }
    -      if (((from_bitField0_ & 0x00040000) != 0)) {
    +      if (((from_bitField0_ & 0x00004000) != 0)) {
             result.iconUrl_ = iconUrl_;
    -        to_bitField0_ |= 0x00000080;
    +        to_bitField0_ |= 0x00000008;
           }
           result.bitField0_ |= to_bitField0_;
         }
    @@ -1882,9 +1576,14 @@ public Builder mergeFrom(com.google.protobuf.Message other) {
     
         public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
           if (other == io.a2a.grpc.AgentCard.getDefaultInstance()) return this;
    -      if (other.hasProtocolVersion()) {
    -        protocolVersion_ = other.protocolVersion_;
    -        bitField0_ |= 0x00000001;
    +      if (!other.protocolVersions_.isEmpty()) {
    +        if (protocolVersions_.isEmpty()) {
    +          protocolVersions_ = other.protocolVersions_;
    +          bitField0_ |= 0x00000001;
    +        } else {
    +          ensureProtocolVersionsIsMutable();
    +          protocolVersions_.addAll(other.protocolVersions_);
    +        }
             onChanged();
           }
           if (!other.getName().isEmpty()) {
    @@ -1923,53 +1622,17 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
               }
             }
           }
    -      if (other.hasUrl()) {
    -        url_ = other.url_;
    -        bitField0_ |= 0x00000010;
    -        onChanged();
    +      if (other.hasProvider()) {
    +        mergeProvider(other.getProvider());
           }
    -      if (other.hasPreferredTransport()) {
    -        preferredTransport_ = other.preferredTransport_;
    +      if (!other.getVersion().isEmpty()) {
    +        version_ = other.version_;
             bitField0_ |= 0x00000020;
             onChanged();
           }
    -      if (additionalInterfacesBuilder_ == null) {
    -        if (!other.additionalInterfaces_.isEmpty()) {
    -          if (additionalInterfaces_.isEmpty()) {
    -            additionalInterfaces_ = other.additionalInterfaces_;
    -            bitField0_ = (bitField0_ & ~0x00000040);
    -          } else {
    -            ensureAdditionalInterfacesIsMutable();
    -            additionalInterfaces_.addAll(other.additionalInterfaces_);
    -          }
    -          onChanged();
    -        }
    -      } else {
    -        if (!other.additionalInterfaces_.isEmpty()) {
    -          if (additionalInterfacesBuilder_.isEmpty()) {
    -            additionalInterfacesBuilder_.dispose();
    -            additionalInterfacesBuilder_ = null;
    -            additionalInterfaces_ = other.additionalInterfaces_;
    -            bitField0_ = (bitField0_ & ~0x00000040);
    -            additionalInterfacesBuilder_ = 
    -              com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
    -                 internalGetAdditionalInterfacesFieldBuilder() : null;
    -          } else {
    -            additionalInterfacesBuilder_.addAllMessages(other.additionalInterfaces_);
    -          }
    -        }
    -      }
    -      if (other.hasProvider()) {
    -        mergeProvider(other.getProvider());
    -      }
    -      if (!other.getVersion().isEmpty()) {
    -        version_ = other.version_;
    -        bitField0_ |= 0x00000100;
    -        onChanged();
    -      }
           if (other.hasDocumentationUrl()) {
             documentationUrl_ = other.documentationUrl_;
    -        bitField0_ |= 0x00000200;
    +        bitField0_ |= 0x00000040;
             onChanged();
           }
           if (other.hasCapabilities()) {
    @@ -1977,12 +1640,12 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
           }
           internalGetMutableSecuritySchemes().mergeFrom(
               other.internalGetSecuritySchemes());
    -      bitField0_ |= 0x00000800;
    +      bitField0_ |= 0x00000100;
           if (securityBuilder_ == null) {
             if (!other.security_.isEmpty()) {
               if (security_.isEmpty()) {
                 security_ = other.security_;
    -            bitField0_ = (bitField0_ & ~0x00001000);
    +            bitField0_ = (bitField0_ & ~0x00000200);
               } else {
                 ensureSecurityIsMutable();
                 security_.addAll(other.security_);
    @@ -1995,7 +1658,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
                 securityBuilder_.dispose();
                 securityBuilder_ = null;
                 security_ = other.security_;
    -            bitField0_ = (bitField0_ & ~0x00001000);
    +            bitField0_ = (bitField0_ & ~0x00000200);
                 securityBuilder_ = 
                   com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                      internalGetSecurityFieldBuilder() : null;
    @@ -2007,7 +1670,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
           if (!other.defaultInputModes_.isEmpty()) {
             if (defaultInputModes_.isEmpty()) {
               defaultInputModes_ = other.defaultInputModes_;
    -          bitField0_ |= 0x00002000;
    +          bitField0_ |= 0x00000400;
             } else {
               ensureDefaultInputModesIsMutable();
               defaultInputModes_.addAll(other.defaultInputModes_);
    @@ -2017,7 +1680,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
           if (!other.defaultOutputModes_.isEmpty()) {
             if (defaultOutputModes_.isEmpty()) {
               defaultOutputModes_ = other.defaultOutputModes_;
    -          bitField0_ |= 0x00004000;
    +          bitField0_ |= 0x00000800;
             } else {
               ensureDefaultOutputModesIsMutable();
               defaultOutputModes_.addAll(other.defaultOutputModes_);
    @@ -2028,7 +1691,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
             if (!other.skills_.isEmpty()) {
               if (skills_.isEmpty()) {
                 skills_ = other.skills_;
    -            bitField0_ = (bitField0_ & ~0x00008000);
    +            bitField0_ = (bitField0_ & ~0x00001000);
               } else {
                 ensureSkillsIsMutable();
                 skills_.addAll(other.skills_);
    @@ -2041,7 +1704,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
                 skillsBuilder_.dispose();
                 skillsBuilder_ = null;
                 skills_ = other.skills_;
    -            bitField0_ = (bitField0_ & ~0x00008000);
    +            bitField0_ = (bitField0_ & ~0x00001000);
                 skillsBuilder_ = 
                   com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                      internalGetSkillsFieldBuilder() : null;
    @@ -2050,14 +1713,11 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
               }
             }
           }
    -      if (other.hasSupportsExtendedAgentCard()) {
    -        setSupportsExtendedAgentCard(other.getSupportsExtendedAgentCard());
    -      }
           if (signaturesBuilder_ == null) {
             if (!other.signatures_.isEmpty()) {
               if (signatures_.isEmpty()) {
                 signatures_ = other.signatures_;
    -            bitField0_ = (bitField0_ & ~0x00020000);
    +            bitField0_ = (bitField0_ & ~0x00002000);
               } else {
                 ensureSignaturesIsMutable();
                 signatures_.addAll(other.signatures_);
    @@ -2070,7 +1730,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
                 signaturesBuilder_.dispose();
                 signaturesBuilder_ = null;
                 signatures_ = other.signatures_;
    -            bitField0_ = (bitField0_ & ~0x00020000);
    +            bitField0_ = (bitField0_ & ~0x00002000);
                 signaturesBuilder_ = 
                   com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                      internalGetSignaturesFieldBuilder() : null;
    @@ -2081,7 +1741,7 @@ public Builder mergeFrom(io.a2a.grpc.AgentCard other) {
           }
           if (other.hasIconUrl()) {
             iconUrl_ = other.iconUrl_;
    -        bitField0_ |= 0x00040000;
    +        bitField0_ |= 0x00004000;
             onChanged();
           }
           this.mergeUnknownFields(other.getUnknownFields());
    @@ -2120,33 +1780,28 @@ public Builder mergeFrom(
                   bitField0_ |= 0x00000004;
                   break;
                 } // case 18
    -            case 26: {
    -              url_ = input.readStringRequireUtf8();
    -              bitField0_ |= 0x00000010;
    -              break;
    -            } // case 26
                 case 34: {
                   input.readMessage(
                       internalGetProviderFieldBuilder().getBuilder(),
                       extensionRegistry);
    -              bitField0_ |= 0x00000080;
    +              bitField0_ |= 0x00000010;
                   break;
                 } // case 34
                 case 42: {
                   version_ = input.readStringRequireUtf8();
    -              bitField0_ |= 0x00000100;
    +              bitField0_ |= 0x00000020;
                   break;
                 } // case 42
                 case 50: {
                   documentationUrl_ = input.readStringRequireUtf8();
    -              bitField0_ |= 0x00000200;
    +              bitField0_ |= 0x00000040;
                   break;
                 } // case 50
                 case 58: {
                   input.readMessage(
                       internalGetCapabilitiesFieldBuilder().getBuilder(),
                       extensionRegistry);
    -              bitField0_ |= 0x00000400;
    +              bitField0_ |= 0x00000080;
                   break;
                 } // case 58
                 case 66: {
    @@ -2155,7 +1810,7 @@ public Builder mergeFrom(
                       SecuritySchemesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
                   internalGetMutableSecuritySchemes().ensureBuilderMap().put(
                       securitySchemes__.getKey(), securitySchemes__.getValue());
    -              bitField0_ |= 0x00000800;
    +              bitField0_ |= 0x00000100;
                   break;
                 } // case 66
                 case 74: {
    @@ -2196,32 +1851,10 @@ public Builder mergeFrom(
                   }
                   break;
                 } // case 98
    -            case 104: {
    -              supportsExtendedAgentCard_ = input.readBool();
    -              bitField0_ |= 0x00010000;
    -              break;
    -            } // case 104
    -            case 114: {
    -              preferredTransport_ = input.readStringRequireUtf8();
    -              bitField0_ |= 0x00000020;
    -              break;
    -            } // case 114
    -            case 122: {
    -              io.a2a.grpc.AgentInterface m =
    -                  input.readMessage(
    -                      io.a2a.grpc.AgentInterface.parser(),
    -                      extensionRegistry);
    -              if (additionalInterfacesBuilder_ == null) {
    -                ensureAdditionalInterfacesIsMutable();
    -                additionalInterfaces_.add(m);
    -              } else {
    -                additionalInterfacesBuilder_.addMessage(m);
    -              }
    -              break;
    -            } // case 122
                 case 130: {
    -              protocolVersion_ = input.readStringRequireUtf8();
    -              bitField0_ |= 0x00000001;
    +              java.lang.String s = input.readStringRequireUtf8();
    +              ensureProtocolVersionsIsMutable();
    +              protocolVersions_.add(s);
                   break;
                 } // case 130
                 case 138: {
    @@ -2239,7 +1872,7 @@ public Builder mergeFrom(
                 } // case 138
                 case 146: {
                   iconUrl_ = input.readStringRequireUtf8();
    -              bitField0_ |= 0x00040000;
    +              bitField0_ |= 0x00004000;
                   break;
                 } // case 146
                 case 154: {
    @@ -2272,110 +1905,175 @@ public Builder mergeFrom(
         }
         private int bitField0_;
     
    -    private java.lang.Object protocolVersion_ = "";
    +    private com.google.protobuf.LazyStringArrayList protocolVersions_ =
    +        com.google.protobuf.LazyStringArrayList.emptyList();
    +    private void ensureProtocolVersionsIsMutable() {
    +      if (!protocolVersions_.isModifiable()) {
    +        protocolVersions_ = new com.google.protobuf.LazyStringArrayList(protocolVersions_);
    +      }
    +      bitField0_ |= 0x00000001;
    +    }
         /**
          * 
    -     * The version of the A2A protocol this agent supports.
    -     * Default: "1.0"
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
          * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return Whether the protocolVersion field is set. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return A list containing the protocolVersions. */ - public boolean hasProtocolVersion() { - return ((bitField0_ & 0x00000001) != 0); + public com.google.protobuf.ProtocolStringList + getProtocolVersionsList() { + protocolVersions_.makeImmutable(); + return protocolVersions_; } /** *
    -     * The version of the A2A protocol this agent supports.
    -     * Default: "1.0"
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
          * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return The protocolVersion. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return The count of protocolVersions. */ - public java.lang.String getProtocolVersion() { - java.lang.Object ref = protocolVersion_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - protocolVersion_ = s; - return s; - } else { - return (java.lang.String) ref; - } + public int getProtocolVersionsCount() { + return protocolVersions_.size(); + } + /** + *
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
    +     * 
    + * + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index of the element to return. + * @return The protocolVersions at the given index. + */ + public java.lang.String getProtocolVersions(int index) { + return protocolVersions_.get(index); } /** *
    -     * The version of the A2A protocol this agent supports.
    -     * Default: "1.0"
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
          * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for protocolVersion. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index of the value to return. + * @return The bytes of the protocolVersions at the given index. */ public com.google.protobuf.ByteString - getProtocolVersionBytes() { - java.lang.Object ref = protocolVersion_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - protocolVersion_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } + getProtocolVersionsBytes(int index) { + return protocolVersions_.getByteString(index); + } + /** + *
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
    +     * 
    + * + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index to set the value at. + * @param value The protocolVersions to set. + * @return This builder for chaining. + */ + public Builder setProtocolVersions( + int index, java.lang.String value) { + if (value == null) { throw new NullPointerException(); } + ensureProtocolVersionsIsMutable(); + protocolVersions_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; } /** *
    -     * The version of the A2A protocol this agent supports.
    -     * Default: "1.0"
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
          * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @param value The protocolVersion to set. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param value The protocolVersions to add. * @return This builder for chaining. */ - public Builder setProtocolVersion( + public Builder addProtocolVersions( java.lang.String value) { if (value == null) { throw new NullPointerException(); } - protocolVersion_ = value; + ensureProtocolVersionsIsMutable(); + protocolVersions_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + /** + *
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
    +     * 
    + * + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param values The protocolVersions to add. + * @return This builder for chaining. + */ + public Builder addAllProtocolVersions( + java.lang.Iterable values) { + ensureProtocolVersionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, protocolVersions_); bitField0_ |= 0x00000001; onChanged(); return this; } /** *
    -     * The version of the A2A protocol this agent supports.
    -     * Default: "1.0"
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
          * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; * @return This builder for chaining. */ - public Builder clearProtocolVersion() { - protocolVersion_ = getDefaultInstance().getProtocolVersion(); - bitField0_ = (bitField0_ & ~0x00000001); + public Builder clearProtocolVersions() { + protocolVersions_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001);; onChanged(); return this; } /** *
    -     * The version of the A2A protocol this agent supports.
    -     * Default: "1.0"
    +     * The versions of the A2A protocol this agent supports.
    +     * For stable versions (1.x+), list only the latest supported minor version per major version.
    +     * For legacy experimental versions (0.x), explicitly list each supported version.
    +     * Default: ["1.0"]
          * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @param value The bytes for protocolVersion to set. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param value The bytes of the protocolVersions to add. * @return This builder for chaining. */ - public Builder setProtocolVersionBytes( + public Builder addProtocolVersionsBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - protocolVersion_ = value; + ensureProtocolVersionsIsMutable(); + protocolVersions_.add(value); bitField0_ |= 0x00000001; onChanged(); return this; @@ -2472,572 +2170,30 @@ public Builder setNameBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - name_ = value; - bitField0_ |= 0x00000002; - onChanged(); - return this; - } - - private java.lang.Object description_ = ""; - /** - *
    -     * A human-readable description of the agent, assisting users and other agents
    -     * in understanding its purpose.
    -     * Example: "Agent that helps users with recipes and cooking."
    -     * 
    - * - * string description = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return The description. - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
    -     * A human-readable description of the agent, assisting users and other agents
    -     * in understanding its purpose.
    -     * Example: "Agent that helps users with recipes and cooking."
    -     * 
    - * - * string description = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for description. - */ - public com.google.protobuf.ByteString - getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
    -     * A human-readable description of the agent, assisting users and other agents
    -     * in understanding its purpose.
    -     * Example: "Agent that helps users with recipes and cooking."
    -     * 
    - * - * string description = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param value The description to set. - * @return This builder for chaining. - */ - public Builder setDescription( - java.lang.String value) { - if (value == null) { throw new NullPointerException(); } - description_ = value; - bitField0_ |= 0x00000004; - onChanged(); - return this; - } - /** - *
    -     * A human-readable description of the agent, assisting users and other agents
    -     * in understanding its purpose.
    -     * Example: "Agent that helps users with recipes and cooking."
    -     * 
    - * - * string description = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return This builder for chaining. - */ - public Builder clearDescription() { - description_ = getDefaultInstance().getDescription(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - *
    -     * A human-readable description of the agent, assisting users and other agents
    -     * in understanding its purpose.
    -     * Example: "Agent that helps users with recipes and cooking."
    -     * 
    - * - * string description = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param value The bytes for description to set. - * @return This builder for chaining. - */ - public Builder setDescriptionBytes( - com.google.protobuf.ByteString value) { - if (value == null) { throw new NullPointerException(); } - checkByteStringIsUtf8(value); - description_ = value; - bitField0_ |= 0x00000004; - onChanged(); - return this; - } - - private java.util.List supportedInterfaces_ = - java.util.Collections.emptyList(); - private void ensureSupportedInterfacesIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - supportedInterfaces_ = new java.util.ArrayList(supportedInterfaces_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder> supportedInterfacesBuilder_; - - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public java.util.List getSupportedInterfacesList() { - if (supportedInterfacesBuilder_ == null) { - return java.util.Collections.unmodifiableList(supportedInterfaces_); - } else { - return supportedInterfacesBuilder_.getMessageList(); - } - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public int getSupportedInterfacesCount() { - if (supportedInterfacesBuilder_ == null) { - return supportedInterfaces_.size(); - } else { - return supportedInterfacesBuilder_.getCount(); - } - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public io.a2a.grpc.AgentInterface getSupportedInterfaces(int index) { - if (supportedInterfacesBuilder_ == null) { - return supportedInterfaces_.get(index); - } else { - return supportedInterfacesBuilder_.getMessage(index); - } - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder setSupportedInterfaces( - int index, io.a2a.grpc.AgentInterface value) { - if (supportedInterfacesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.set(index, value); - onChanged(); - } else { - supportedInterfacesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder setSupportedInterfaces( - int index, io.a2a.grpc.AgentInterface.Builder builderForValue) { - if (supportedInterfacesBuilder_ == null) { - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.set(index, builderForValue.build()); - onChanged(); - } else { - supportedInterfacesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder addSupportedInterfaces(io.a2a.grpc.AgentInterface value) { - if (supportedInterfacesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.add(value); - onChanged(); - } else { - supportedInterfacesBuilder_.addMessage(value); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder addSupportedInterfaces( - int index, io.a2a.grpc.AgentInterface value) { - if (supportedInterfacesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.add(index, value); - onChanged(); - } else { - supportedInterfacesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder addSupportedInterfaces( - io.a2a.grpc.AgentInterface.Builder builderForValue) { - if (supportedInterfacesBuilder_ == null) { - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.add(builderForValue.build()); - onChanged(); - } else { - supportedInterfacesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder addSupportedInterfaces( - int index, io.a2a.grpc.AgentInterface.Builder builderForValue) { - if (supportedInterfacesBuilder_ == null) { - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.add(index, builderForValue.build()); - onChanged(); - } else { - supportedInterfacesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder addAllSupportedInterfaces( - java.lang.Iterable values) { - if (supportedInterfacesBuilder_ == null) { - ensureSupportedInterfacesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, supportedInterfaces_); - onChanged(); - } else { - supportedInterfacesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder clearSupportedInterfaces() { - if (supportedInterfacesBuilder_ == null) { - supportedInterfaces_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - supportedInterfacesBuilder_.clear(); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public Builder removeSupportedInterfaces(int index) { - if (supportedInterfacesBuilder_ == null) { - ensureSupportedInterfacesIsMutable(); - supportedInterfaces_.remove(index); - onChanged(); - } else { - supportedInterfacesBuilder_.remove(index); - } - return this; - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public io.a2a.grpc.AgentInterface.Builder getSupportedInterfacesBuilder( - int index) { - return internalGetSupportedInterfacesFieldBuilder().getBuilder(index); - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public io.a2a.grpc.AgentInterfaceOrBuilder getSupportedInterfacesOrBuilder( - int index) { - if (supportedInterfacesBuilder_ == null) { - return supportedInterfaces_.get(index); } else { - return supportedInterfacesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public java.util.List - getSupportedInterfacesOrBuilderList() { - if (supportedInterfacesBuilder_ != null) { - return supportedInterfacesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(supportedInterfaces_); - } - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public io.a2a.grpc.AgentInterface.Builder addSupportedInterfacesBuilder() { - return internalGetSupportedInterfacesFieldBuilder().addBuilder( - io.a2a.grpc.AgentInterface.getDefaultInstance()); - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public io.a2a.grpc.AgentInterface.Builder addSupportedInterfacesBuilder( - int index) { - return internalGetSupportedInterfacesFieldBuilder().addBuilder( - index, io.a2a.grpc.AgentInterface.getDefaultInstance()); - } - /** - *
    -     * Ordered list of supported interfaces. First entry is preferred.
    -     * 
    - * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; - */ - public java.util.List - getSupportedInterfacesBuilderList() { - return internalGetSupportedInterfacesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder> - internalGetSupportedInterfacesFieldBuilder() { - if (supportedInterfacesBuilder_ == null) { - supportedInterfacesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder>( - supportedInterfaces_, - ((bitField0_ & 0x00000008) != 0), - getParentForChildren(), - isClean()); - supportedInterfaces_ = null; - } - return supportedInterfacesBuilder_; - } - - private java.lang.Object url_ = ""; - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return Whether the url field is set. - */ - @java.lang.Deprecated public boolean hasUrl() { - return ((bitField0_ & 0x00000010) != 0); - } - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return The url. - */ - @java.lang.Deprecated public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return The bytes for url. - */ - @java.lang.Deprecated public com.google.protobuf.ByteString - getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @param value The url to set. - * @return This builder for chaining. - */ - @java.lang.Deprecated public Builder setUrl( - java.lang.String value) { - if (value == null) { throw new NullPointerException(); } - url_ = value; - bitField0_ |= 0x00000010; - onChanged(); - return this; - } - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return This builder for chaining. - */ - @java.lang.Deprecated public Builder clearUrl() { - url_ = getDefaultInstance().getUrl(); - bitField0_ = (bitField0_ & ~0x00000010); - onChanged(); - return this; - } - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @param value The bytes for url to set. - * @return This builder for chaining. - */ - @java.lang.Deprecated public Builder setUrlBytes( - com.google.protobuf.ByteString value) { - if (value == null) { throw new NullPointerException(); } - checkByteStringIsUtf8(value); - url_ = value; - bitField0_ |= 0x00000010; - onChanged(); - return this; - } - - private java.lang.Object preferredTransport_ = ""; - /** - *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    -     * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return Whether the preferredTransport field is set. - */ - @java.lang.Deprecated public boolean hasPreferredTransport() { - return ((bitField0_ & 0x00000020) != 0); + name_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; } + + private java.lang.Object description_ = ""; /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * A human-readable description of the agent, assisting users and other agents
    +     * in understanding its purpose.
    +     * Example: "Agent that helps users with recipes and cooking."
          * 
    * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return The preferredTransport. + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return The description. */ - @java.lang.Deprecated public java.lang.String getPreferredTransport() { - java.lang.Object ref = preferredTransport_; + public java.lang.String getDescription() { + java.lang.Object ref = description_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); - preferredTransport_ = s; + description_ = s; return s; } else { return (java.lang.String) ref; @@ -3045,22 +2201,22 @@ public io.a2a.grpc.AgentInterface.Builder addSupportedInterfacesBuilder( } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * A human-readable description of the agent, assisting users and other agents
    +     * in understanding its purpose.
    +     * Example: "Agent that helps users with recipes and cooking."
          * 
    * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return The bytes for preferredTransport. + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return The bytes for description. */ - @java.lang.Deprecated public com.google.protobuf.ByteString - getPreferredTransportBytes() { - java.lang.Object ref = preferredTransport_; + public com.google.protobuf.ByteString + getDescriptionBytes() { + java.lang.Object ref = description_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - preferredTransport_ = b; + description_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; @@ -3068,370 +2224,370 @@ public io.a2a.grpc.AgentInterface.Builder addSupportedInterfacesBuilder( } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * A human-readable description of the agent, assisting users and other agents
    +     * in understanding its purpose.
    +     * Example: "Agent that helps users with recipes and cooking."
          * 
    * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @param value The preferredTransport to set. + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param value The description to set. * @return This builder for chaining. */ - @java.lang.Deprecated public Builder setPreferredTransport( + public Builder setDescription( java.lang.String value) { if (value == null) { throw new NullPointerException(); } - preferredTransport_ = value; - bitField0_ |= 0x00000020; + description_ = value; + bitField0_ |= 0x00000004; onChanged(); return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * A human-readable description of the agent, assisting users and other agents
    +     * in understanding its purpose.
    +     * Example: "Agent that helps users with recipes and cooking."
          * 
    * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; * @return This builder for chaining. */ - @java.lang.Deprecated public Builder clearPreferredTransport() { - preferredTransport_ = getDefaultInstance().getPreferredTransport(); - bitField0_ = (bitField0_ & ~0x00000020); + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * A human-readable description of the agent, assisting users and other agents
    +     * in understanding its purpose.
    +     * Example: "Agent that helps users with recipes and cooking."
          * 
    * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @param value The bytes for preferredTransport to set. + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param value The bytes for description to set. * @return This builder for chaining. */ - @java.lang.Deprecated public Builder setPreferredTransportBytes( + public Builder setDescriptionBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - preferredTransport_ = value; - bitField0_ |= 0x00000020; + description_ = value; + bitField0_ |= 0x00000004; onChanged(); return this; } - private java.util.List additionalInterfaces_ = + private java.util.List supportedInterfaces_ = java.util.Collections.emptyList(); - private void ensureAdditionalInterfacesIsMutable() { - if (!((bitField0_ & 0x00000040) != 0)) { - additionalInterfaces_ = new java.util.ArrayList(additionalInterfaces_); - bitField0_ |= 0x00000040; + private void ensureSupportedInterfacesIsMutable() { + if (!((bitField0_ & 0x00000008) != 0)) { + supportedInterfaces_ = new java.util.ArrayList(supportedInterfaces_); + bitField0_ |= 0x00000008; } } private com.google.protobuf.RepeatedFieldBuilder< - io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder> additionalInterfacesBuilder_; + io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder> supportedInterfacesBuilder_; /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public java.util.List getAdditionalInterfacesList() { - if (additionalInterfacesBuilder_ == null) { - return java.util.Collections.unmodifiableList(additionalInterfaces_); + public java.util.List getSupportedInterfacesList() { + if (supportedInterfacesBuilder_ == null) { + return java.util.Collections.unmodifiableList(supportedInterfaces_); } else { - return additionalInterfacesBuilder_.getMessageList(); + return supportedInterfacesBuilder_.getMessageList(); } } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public int getAdditionalInterfacesCount() { - if (additionalInterfacesBuilder_ == null) { - return additionalInterfaces_.size(); + public int getSupportedInterfacesCount() { + if (supportedInterfacesBuilder_ == null) { + return supportedInterfaces_.size(); } else { - return additionalInterfacesBuilder_.getCount(); + return supportedInterfacesBuilder_.getCount(); } } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public io.a2a.grpc.AgentInterface getAdditionalInterfaces(int index) { - if (additionalInterfacesBuilder_ == null) { - return additionalInterfaces_.get(index); + public io.a2a.grpc.AgentInterface getSupportedInterfaces(int index) { + if (supportedInterfacesBuilder_ == null) { + return supportedInterfaces_.get(index); } else { - return additionalInterfacesBuilder_.getMessage(index); + return supportedInterfacesBuilder_.getMessage(index); } } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder setAdditionalInterfaces( + public Builder setSupportedInterfaces( int index, io.a2a.grpc.AgentInterface value) { - if (additionalInterfacesBuilder_ == null) { + if (supportedInterfacesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.set(index, value); + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.set(index, value); onChanged(); } else { - additionalInterfacesBuilder_.setMessage(index, value); + supportedInterfacesBuilder_.setMessage(index, value); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder setAdditionalInterfaces( + public Builder setSupportedInterfaces( int index, io.a2a.grpc.AgentInterface.Builder builderForValue) { - if (additionalInterfacesBuilder_ == null) { - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.set(index, builderForValue.build()); + if (supportedInterfacesBuilder_ == null) { + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.set(index, builderForValue.build()); onChanged(); } else { - additionalInterfacesBuilder_.setMessage(index, builderForValue.build()); + supportedInterfacesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder addAdditionalInterfaces(io.a2a.grpc.AgentInterface value) { - if (additionalInterfacesBuilder_ == null) { + public Builder addSupportedInterfaces(io.a2a.grpc.AgentInterface value) { + if (supportedInterfacesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.add(value); + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.add(value); onChanged(); } else { - additionalInterfacesBuilder_.addMessage(value); + supportedInterfacesBuilder_.addMessage(value); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder addAdditionalInterfaces( + public Builder addSupportedInterfaces( int index, io.a2a.grpc.AgentInterface value) { - if (additionalInterfacesBuilder_ == null) { + if (supportedInterfacesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.add(index, value); + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.add(index, value); onChanged(); } else { - additionalInterfacesBuilder_.addMessage(index, value); + supportedInterfacesBuilder_.addMessage(index, value); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder addAdditionalInterfaces( + public Builder addSupportedInterfaces( io.a2a.grpc.AgentInterface.Builder builderForValue) { - if (additionalInterfacesBuilder_ == null) { - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.add(builderForValue.build()); + if (supportedInterfacesBuilder_ == null) { + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.add(builderForValue.build()); onChanged(); } else { - additionalInterfacesBuilder_.addMessage(builderForValue.build()); + supportedInterfacesBuilder_.addMessage(builderForValue.build()); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder addAdditionalInterfaces( + public Builder addSupportedInterfaces( int index, io.a2a.grpc.AgentInterface.Builder builderForValue) { - if (additionalInterfacesBuilder_ == null) { - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.add(index, builderForValue.build()); + if (supportedInterfacesBuilder_ == null) { + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.add(index, builderForValue.build()); onChanged(); } else { - additionalInterfacesBuilder_.addMessage(index, builderForValue.build()); + supportedInterfacesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder addAllAdditionalInterfaces( + public Builder addAllSupportedInterfaces( java.lang.Iterable values) { - if (additionalInterfacesBuilder_ == null) { - ensureAdditionalInterfacesIsMutable(); + if (supportedInterfacesBuilder_ == null) { + ensureSupportedInterfacesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, additionalInterfaces_); + values, supportedInterfaces_); onChanged(); } else { - additionalInterfacesBuilder_.addAllMessages(values); + supportedInterfacesBuilder_.addAllMessages(values); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder clearAdditionalInterfaces() { - if (additionalInterfacesBuilder_ == null) { - additionalInterfaces_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); + public Builder clearSupportedInterfaces() { + if (supportedInterfacesBuilder_ == null) { + supportedInterfaces_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); onChanged(); } else { - additionalInterfacesBuilder_.clear(); + supportedInterfacesBuilder_.clear(); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public Builder removeAdditionalInterfaces(int index) { - if (additionalInterfacesBuilder_ == null) { - ensureAdditionalInterfacesIsMutable(); - additionalInterfaces_.remove(index); + public Builder removeSupportedInterfaces(int index) { + if (supportedInterfacesBuilder_ == null) { + ensureSupportedInterfacesIsMutable(); + supportedInterfaces_.remove(index); onChanged(); } else { - additionalInterfacesBuilder_.remove(index); + supportedInterfacesBuilder_.remove(index); } return this; } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public io.a2a.grpc.AgentInterface.Builder getAdditionalInterfacesBuilder( + public io.a2a.grpc.AgentInterface.Builder getSupportedInterfacesBuilder( int index) { - return internalGetAdditionalInterfacesFieldBuilder().getBuilder(index); + return internalGetSupportedInterfacesFieldBuilder().getBuilder(index); } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public io.a2a.grpc.AgentInterfaceOrBuilder getAdditionalInterfacesOrBuilder( + public io.a2a.grpc.AgentInterfaceOrBuilder getSupportedInterfacesOrBuilder( int index) { - if (additionalInterfacesBuilder_ == null) { - return additionalInterfaces_.get(index); } else { - return additionalInterfacesBuilder_.getMessageOrBuilder(index); + if (supportedInterfacesBuilder_ == null) { + return supportedInterfaces_.get(index); } else { + return supportedInterfacesBuilder_.getMessageOrBuilder(index); } } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public java.util.List - getAdditionalInterfacesOrBuilderList() { - if (additionalInterfacesBuilder_ != null) { - return additionalInterfacesBuilder_.getMessageOrBuilderList(); + public java.util.List + getSupportedInterfacesOrBuilderList() { + if (supportedInterfacesBuilder_ != null) { + return supportedInterfacesBuilder_.getMessageOrBuilderList(); } else { - return java.util.Collections.unmodifiableList(additionalInterfaces_); + return java.util.Collections.unmodifiableList(supportedInterfaces_); } } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public io.a2a.grpc.AgentInterface.Builder addAdditionalInterfacesBuilder() { - return internalGetAdditionalInterfacesFieldBuilder().addBuilder( + public io.a2a.grpc.AgentInterface.Builder addSupportedInterfacesBuilder() { + return internalGetSupportedInterfacesFieldBuilder().addBuilder( io.a2a.grpc.AgentInterface.getDefaultInstance()); } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public io.a2a.grpc.AgentInterface.Builder addAdditionalInterfacesBuilder( + public io.a2a.grpc.AgentInterface.Builder addSupportedInterfacesBuilder( int index) { - return internalGetAdditionalInterfacesFieldBuilder().addBuilder( + return internalGetSupportedInterfacesFieldBuilder().addBuilder( index, io.a2a.grpc.AgentInterface.getDefaultInstance()); } /** *
    -     * DEPRECATED: Use 'supported_interfaces' instead.
    +     * Ordered list of supported interfaces. First entry is preferred.
          * 
    * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ - @java.lang.Deprecated public java.util.List - getAdditionalInterfacesBuilderList() { - return internalGetAdditionalInterfacesFieldBuilder().getBuilderList(); + public java.util.List + getSupportedInterfacesBuilderList() { + return internalGetSupportedInterfacesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilder< io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder> - internalGetAdditionalInterfacesFieldBuilder() { - if (additionalInterfacesBuilder_ == null) { - additionalInterfacesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< + internalGetSupportedInterfacesFieldBuilder() { + if (supportedInterfacesBuilder_ == null) { + supportedInterfacesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< io.a2a.grpc.AgentInterface, io.a2a.grpc.AgentInterface.Builder, io.a2a.grpc.AgentInterfaceOrBuilder>( - additionalInterfaces_, - ((bitField0_ & 0x00000040) != 0), + supportedInterfaces_, + ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); - additionalInterfaces_ = null; + supportedInterfaces_ = null; } - return additionalInterfacesBuilder_; + return supportedInterfacesBuilder_; } private io.a2a.grpc.AgentProvider provider_; @@ -3446,7 +2602,7 @@ private void ensureAdditionalInterfacesIsMutable() { * @return Whether the provider field is set. */ public boolean hasProvider() { - return ((bitField0_ & 0x00000080) != 0); + return ((bitField0_ & 0x00000010) != 0); } /** *
    @@ -3479,7 +2635,7 @@ public Builder setProvider(io.a2a.grpc.AgentProvider value) {
           } else {
             providerBuilder_.setMessage(value);
           }
    -      bitField0_ |= 0x00000080;
    +      bitField0_ |= 0x00000010;
           onChanged();
           return this;
         }
    @@ -3497,7 +2653,7 @@ public Builder setProvider(
           } else {
             providerBuilder_.setMessage(builderForValue.build());
           }
    -      bitField0_ |= 0x00000080;
    +      bitField0_ |= 0x00000010;
           onChanged();
           return this;
         }
    @@ -3510,7 +2666,7 @@ public Builder setProvider(
          */
         public Builder mergeProvider(io.a2a.grpc.AgentProvider value) {
           if (providerBuilder_ == null) {
    -        if (((bitField0_ & 0x00000080) != 0) &&
    +        if (((bitField0_ & 0x00000010) != 0) &&
               provider_ != null &&
               provider_ != io.a2a.grpc.AgentProvider.getDefaultInstance()) {
               getProviderBuilder().mergeFrom(value);
    @@ -3521,7 +2677,7 @@ public Builder mergeProvider(io.a2a.grpc.AgentProvider value) {
             providerBuilder_.mergeFrom(value);
           }
           if (provider_ != null) {
    -        bitField0_ |= 0x00000080;
    +        bitField0_ |= 0x00000010;
             onChanged();
           }
           return this;
    @@ -3534,7 +2690,7 @@ public Builder mergeProvider(io.a2a.grpc.AgentProvider value) {
          * .a2a.v1.AgentProvider provider = 4;
          */
         public Builder clearProvider() {
    -      bitField0_ = (bitField0_ & ~0x00000080);
    +      bitField0_ = (bitField0_ & ~0x00000010);
           provider_ = null;
           if (providerBuilder_ != null) {
             providerBuilder_.dispose();
    @@ -3551,7 +2707,7 @@ public Builder clearProvider() {
          * .a2a.v1.AgentProvider provider = 4;
          */
         public io.a2a.grpc.AgentProvider.Builder getProviderBuilder() {
    -      bitField0_ |= 0x00000080;
    +      bitField0_ |= 0x00000010;
           onChanged();
           return internalGetProviderFieldBuilder().getBuilder();
         }
    @@ -3649,7 +2805,7 @@ public Builder setVersion(
             java.lang.String value) {
           if (value == null) { throw new NullPointerException(); }
           version_ = value;
    -      bitField0_ |= 0x00000100;
    +      bitField0_ |= 0x00000020;
           onChanged();
           return this;
         }
    @@ -3664,7 +2820,7 @@ public Builder setVersion(
          */
         public Builder clearVersion() {
           version_ = getDefaultInstance().getVersion();
    -      bitField0_ = (bitField0_ & ~0x00000100);
    +      bitField0_ = (bitField0_ & ~0x00000020);
           onChanged();
           return this;
         }
    @@ -3683,7 +2839,7 @@ public Builder setVersionBytes(
           if (value == null) { throw new NullPointerException(); }
           checkByteStringIsUtf8(value);
           version_ = value;
    -      bitField0_ |= 0x00000100;
    +      bitField0_ |= 0x00000020;
           onChanged();
           return this;
         }
    @@ -3698,7 +2854,7 @@ public Builder setVersionBytes(
          * @return Whether the documentationUrl field is set.
          */
         public boolean hasDocumentationUrl() {
    -      return ((bitField0_ & 0x00000200) != 0);
    +      return ((bitField0_ & 0x00000040) != 0);
         }
         /**
          * 
    @@ -3754,7 +2910,7 @@ public Builder setDocumentationUrl(
             java.lang.String value) {
           if (value == null) { throw new NullPointerException(); }
           documentationUrl_ = value;
    -      bitField0_ |= 0x00000200;
    +      bitField0_ |= 0x00000040;
           onChanged();
           return this;
         }
    @@ -3768,7 +2924,7 @@ public Builder setDocumentationUrl(
          */
         public Builder clearDocumentationUrl() {
           documentationUrl_ = getDefaultInstance().getDocumentationUrl();
    -      bitField0_ = (bitField0_ & ~0x00000200);
    +      bitField0_ = (bitField0_ & ~0x00000040);
           onChanged();
           return this;
         }
    @@ -3786,7 +2942,7 @@ public Builder setDocumentationUrlBytes(
           if (value == null) { throw new NullPointerException(); }
           checkByteStringIsUtf8(value);
           documentationUrl_ = value;
    -      bitField0_ |= 0x00000200;
    +      bitField0_ |= 0x00000040;
           onChanged();
           return this;
         }
    @@ -3803,7 +2959,7 @@ public Builder setDocumentationUrlBytes(
          * @return Whether the capabilities field is set.
          */
         public boolean hasCapabilities() {
    -      return ((bitField0_ & 0x00000400) != 0);
    +      return ((bitField0_ & 0x00000080) != 0);
         }
         /**
          * 
    @@ -3836,7 +2992,7 @@ public Builder setCapabilities(io.a2a.grpc.AgentCapabilities value) {
           } else {
             capabilitiesBuilder_.setMessage(value);
           }
    -      bitField0_ |= 0x00000400;
    +      bitField0_ |= 0x00000080;
           onChanged();
           return this;
         }
    @@ -3854,7 +3010,7 @@ public Builder setCapabilities(
           } else {
             capabilitiesBuilder_.setMessage(builderForValue.build());
           }
    -      bitField0_ |= 0x00000400;
    +      bitField0_ |= 0x00000080;
           onChanged();
           return this;
         }
    @@ -3867,7 +3023,7 @@ public Builder setCapabilities(
          */
         public Builder mergeCapabilities(io.a2a.grpc.AgentCapabilities value) {
           if (capabilitiesBuilder_ == null) {
    -        if (((bitField0_ & 0x00000400) != 0) &&
    +        if (((bitField0_ & 0x00000080) != 0) &&
               capabilities_ != null &&
               capabilities_ != io.a2a.grpc.AgentCapabilities.getDefaultInstance()) {
               getCapabilitiesBuilder().mergeFrom(value);
    @@ -3878,7 +3034,7 @@ public Builder mergeCapabilities(io.a2a.grpc.AgentCapabilities value) {
             capabilitiesBuilder_.mergeFrom(value);
           }
           if (capabilities_ != null) {
    -        bitField0_ |= 0x00000400;
    +        bitField0_ |= 0x00000080;
             onChanged();
           }
           return this;
    @@ -3891,7 +3047,7 @@ public Builder mergeCapabilities(io.a2a.grpc.AgentCapabilities value) {
          * .a2a.v1.AgentCapabilities capabilities = 7 [(.google.api.field_behavior) = REQUIRED];
          */
         public Builder clearCapabilities() {
    -      bitField0_ = (bitField0_ & ~0x00000400);
    +      bitField0_ = (bitField0_ & ~0x00000080);
           capabilities_ = null;
           if (capabilitiesBuilder_ != null) {
             capabilitiesBuilder_.dispose();
    @@ -3908,7 +3064,7 @@ public Builder clearCapabilities() {
          * .a2a.v1.AgentCapabilities capabilities = 7 [(.google.api.field_behavior) = REQUIRED];
          */
         public io.a2a.grpc.AgentCapabilities.Builder getCapabilitiesBuilder() {
    -      bitField0_ |= 0x00000400;
    +      bitField0_ |= 0x00000080;
           onChanged();
           return internalGetCapabilitiesFieldBuilder().getBuilder();
         }
    @@ -3976,7 +3132,7 @@ public com.google.protobuf.MapEntry(securitySchemesConverter);
           }
    -      bitField0_ |= 0x00000800;
    +      bitField0_ |= 0x00000100;
           onChanged();
           return securitySchemes_;
         }
    @@ -4050,7 +3206,7 @@ public io.a2a.grpc.SecurityScheme getSecuritySchemesOrThrow(
           return securitySchemesConverter.build(map.get(key));
         }
         public Builder clearSecuritySchemes() {
    -      bitField0_ = (bitField0_ & ~0x00000800);
    +      bitField0_ = (bitField0_ & ~0x00000100);
           internalGetMutableSecuritySchemes().clear();
           return this;
         }
    @@ -4074,7 +3230,7 @@ public Builder removeSecuritySchemes(
         @java.lang.Deprecated
         public java.util.Map
             getMutableSecuritySchemes() {
    -      bitField0_ |= 0x00000800;
    +      bitField0_ |= 0x00000100;
           return internalGetMutableSecuritySchemes().ensureMessageMap();
         }
         /**
    @@ -4091,7 +3247,7 @@ public Builder putSecuritySchemes(
           if (value == null) { throw new NullPointerException("map value"); }
           internalGetMutableSecuritySchemes().ensureBuilderMap()
               .put(key, value);
    -      bitField0_ |= 0x00000800;
    +      bitField0_ |= 0x00000100;
           return this;
         }
         /**
    @@ -4110,7 +3266,7 @@ public Builder putAllSecuritySchemes(
           }
           internalGetMutableSecuritySchemes().ensureBuilderMap()
               .putAll(values);
    -      bitField0_ |= 0x00000800;
    +      bitField0_ |= 0x00000100;
           return this;
         }
         /**
    @@ -4138,9 +3294,9 @@ public io.a2a.grpc.SecurityScheme.Builder putSecuritySchemesBuilderIfAbsent(
         private java.util.List security_ =
           java.util.Collections.emptyList();
         private void ensureSecurityIsMutable() {
    -      if (!((bitField0_ & 0x00001000) != 0)) {
    +      if (!((bitField0_ & 0x00000200) != 0)) {
             security_ = new java.util.ArrayList(security_);
    -        bitField0_ |= 0x00001000;
    +        bitField0_ |= 0x00000200;
            }
         }
     
    @@ -4345,7 +3501,7 @@ public Builder addAllSecurity(
         public Builder clearSecurity() {
           if (securityBuilder_ == null) {
             security_ = java.util.Collections.emptyList();
    -        bitField0_ = (bitField0_ & ~0x00001000);
    +        bitField0_ = (bitField0_ & ~0x00000200);
             onChanged();
           } else {
             securityBuilder_.clear();
    @@ -4457,7 +3613,7 @@ public io.a2a.grpc.Security.Builder addSecurityBuilder(
             securityBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                 io.a2a.grpc.Security, io.a2a.grpc.Security.Builder, io.a2a.grpc.SecurityOrBuilder>(
                     security_,
    -                ((bitField0_ & 0x00001000) != 0),
    +                ((bitField0_ & 0x00000200) != 0),
                     getParentForChildren(),
                     isClean());
             security_ = null;
    @@ -4471,7 +3627,7 @@ private void ensureDefaultInputModesIsMutable() {
           if (!defaultInputModes_.isModifiable()) {
             defaultInputModes_ = new com.google.protobuf.LazyStringArrayList(defaultInputModes_);
           }
    -      bitField0_ |= 0x00002000;
    +      bitField0_ |= 0x00000400;
         }
         /**
          * 
    @@ -4547,7 +3703,7 @@ public Builder setDefaultInputModes(
           if (value == null) { throw new NullPointerException(); }
           ensureDefaultInputModesIsMutable();
           defaultInputModes_.set(index, value);
    -      bitField0_ |= 0x00002000;
    +      bitField0_ |= 0x00000400;
           onChanged();
           return this;
         }
    @@ -4567,7 +3723,7 @@ public Builder addDefaultInputModes(
           if (value == null) { throw new NullPointerException(); }
           ensureDefaultInputModesIsMutable();
           defaultInputModes_.add(value);
    -      bitField0_ |= 0x00002000;
    +      bitField0_ |= 0x00000400;
           onChanged();
           return this;
         }
    @@ -4587,7 +3743,7 @@ public Builder addAllDefaultInputModes(
           ensureDefaultInputModesIsMutable();
           com.google.protobuf.AbstractMessageLite.Builder.addAll(
               values, defaultInputModes_);
    -      bitField0_ |= 0x00002000;
    +      bitField0_ |= 0x00000400;
           onChanged();
           return this;
         }
    @@ -4604,7 +3760,7 @@ public Builder addAllDefaultInputModes(
         public Builder clearDefaultInputModes() {
           defaultInputModes_ =
             com.google.protobuf.LazyStringArrayList.emptyList();
    -      bitField0_ = (bitField0_ & ~0x00002000);;
    +      bitField0_ = (bitField0_ & ~0x00000400);;
           onChanged();
           return this;
         }
    @@ -4625,7 +3781,7 @@ public Builder addDefaultInputModesBytes(
           checkByteStringIsUtf8(value);
           ensureDefaultInputModesIsMutable();
           defaultInputModes_.add(value);
    -      bitField0_ |= 0x00002000;
    +      bitField0_ |= 0x00000400;
           onChanged();
           return this;
         }
    @@ -4636,7 +3792,7 @@ private void ensureDefaultOutputModesIsMutable() {
           if (!defaultOutputModes_.isModifiable()) {
             defaultOutputModes_ = new com.google.protobuf.LazyStringArrayList(defaultOutputModes_);
           }
    -      bitField0_ |= 0x00004000;
    +      bitField0_ |= 0x00000800;
         }
         /**
          * 
    @@ -4702,7 +3858,7 @@ public Builder setDefaultOutputModes(
           if (value == null) { throw new NullPointerException(); }
           ensureDefaultOutputModesIsMutable();
           defaultOutputModes_.set(index, value);
    -      bitField0_ |= 0x00004000;
    +      bitField0_ |= 0x00000800;
           onChanged();
           return this;
         }
    @@ -4720,7 +3876,7 @@ public Builder addDefaultOutputModes(
           if (value == null) { throw new NullPointerException(); }
           ensureDefaultOutputModesIsMutable();
           defaultOutputModes_.add(value);
    -      bitField0_ |= 0x00004000;
    +      bitField0_ |= 0x00000800;
           onChanged();
           return this;
         }
    @@ -4738,7 +3894,7 @@ public Builder addAllDefaultOutputModes(
           ensureDefaultOutputModesIsMutable();
           com.google.protobuf.AbstractMessageLite.Builder.addAll(
               values, defaultOutputModes_);
    -      bitField0_ |= 0x00004000;
    +      bitField0_ |= 0x00000800;
           onChanged();
           return this;
         }
    @@ -4753,7 +3909,7 @@ public Builder addAllDefaultOutputModes(
         public Builder clearDefaultOutputModes() {
           defaultOutputModes_ =
             com.google.protobuf.LazyStringArrayList.emptyList();
    -      bitField0_ = (bitField0_ & ~0x00004000);;
    +      bitField0_ = (bitField0_ & ~0x00000800);;
           onChanged();
           return this;
         }
    @@ -4772,7 +3928,7 @@ public Builder addDefaultOutputModesBytes(
           checkByteStringIsUtf8(value);
           ensureDefaultOutputModesIsMutable();
           defaultOutputModes_.add(value);
    -      bitField0_ |= 0x00004000;
    +      bitField0_ |= 0x00000800;
           onChanged();
           return this;
         }
    @@ -4780,9 +3936,9 @@ public Builder addDefaultOutputModesBytes(
         private java.util.List skills_ =
           java.util.Collections.emptyList();
         private void ensureSkillsIsMutable() {
    -      if (!((bitField0_ & 0x00008000) != 0)) {
    +      if (!((bitField0_ & 0x00001000) != 0)) {
             skills_ = new java.util.ArrayList(skills_);
    -        bitField0_ |= 0x00008000;
    +        bitField0_ |= 0x00001000;
            }
         }
     
    @@ -4998,7 +4154,7 @@ public Builder addAllSkills(
         public Builder clearSkills() {
           if (skillsBuilder_ == null) {
             skills_ = java.util.Collections.emptyList();
    -        bitField0_ = (bitField0_ & ~0x00008000);
    +        bitField0_ = (bitField0_ & ~0x00001000);
             onChanged();
           } else {
             skillsBuilder_.clear();
    @@ -5117,7 +4273,7 @@ public io.a2a.grpc.AgentSkill.Builder addSkillsBuilder(
             skillsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                 io.a2a.grpc.AgentSkill, io.a2a.grpc.AgentSkill.Builder, io.a2a.grpc.AgentSkillOrBuilder>(
                     skills_,
    -                ((bitField0_ & 0x00008000) != 0),
    +                ((bitField0_ & 0x00001000) != 0),
                     getParentForChildren(),
                     isClean());
             skills_ = null;
    @@ -5125,68 +4281,12 @@ public io.a2a.grpc.AgentSkill.Builder addSkillsBuilder(
           return skillsBuilder_;
         }
     
    -    private boolean supportsExtendedAgentCard_ ;
    -    /**
    -     * 
    -     * Whether the agent supports providing an extended agent card when authenticated.
    -     * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return Whether the supportsExtendedAgentCard field is set. - */ - @java.lang.Override - public boolean hasSupportsExtendedAgentCard() { - return ((bitField0_ & 0x00010000) != 0); - } - /** - *
    -     * Whether the agent supports providing an extended agent card when authenticated.
    -     * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return The supportsExtendedAgentCard. - */ - @java.lang.Override - public boolean getSupportsExtendedAgentCard() { - return supportsExtendedAgentCard_; - } - /** - *
    -     * Whether the agent supports providing an extended agent card when authenticated.
    -     * 
    - * - * optional bool supports_extended_agent_card = 13; - * @param value The supportsExtendedAgentCard to set. - * @return This builder for chaining. - */ - public Builder setSupportsExtendedAgentCard(boolean value) { - - supportsExtendedAgentCard_ = value; - bitField0_ |= 0x00010000; - onChanged(); - return this; - } - /** - *
    -     * Whether the agent supports providing an extended agent card when authenticated.
    -     * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return This builder for chaining. - */ - public Builder clearSupportsExtendedAgentCard() { - bitField0_ = (bitField0_ & ~0x00010000); - supportsExtendedAgentCard_ = false; - onChanged(); - return this; - } - private java.util.List signatures_ = java.util.Collections.emptyList(); private void ensureSignaturesIsMutable() { - if (!((bitField0_ & 0x00020000) != 0)) { + if (!((bitField0_ & 0x00002000) != 0)) { signatures_ = new java.util.ArrayList(signatures_); - bitField0_ |= 0x00020000; + bitField0_ |= 0x00002000; } } @@ -5380,7 +4480,7 @@ public Builder addAllSignatures( public Builder clearSignatures() { if (signaturesBuilder_ == null) { signatures_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00020000); + bitField0_ = (bitField0_ & ~0x00002000); onChanged(); } else { signaturesBuilder_.clear(); @@ -5485,7 +4585,7 @@ public io.a2a.grpc.AgentCardSignature.Builder addSignaturesBuilder( signaturesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< io.a2a.grpc.AgentCardSignature, io.a2a.grpc.AgentCardSignature.Builder, io.a2a.grpc.AgentCardSignatureOrBuilder>( signatures_, - ((bitField0_ & 0x00020000) != 0), + ((bitField0_ & 0x00002000) != 0), getParentForChildren(), isClean()); signatures_ = null; @@ -5503,7 +4603,7 @@ public io.a2a.grpc.AgentCardSignature.Builder addSignaturesBuilder( * @return Whether the iconUrl field is set. */ public boolean hasIconUrl() { - return ((bitField0_ & 0x00040000) != 0); + return ((bitField0_ & 0x00004000) != 0); } /** *
    @@ -5559,7 +4659,7 @@ public Builder setIconUrl(
             java.lang.String value) {
           if (value == null) { throw new NullPointerException(); }
           iconUrl_ = value;
    -      bitField0_ |= 0x00040000;
    +      bitField0_ |= 0x00004000;
           onChanged();
           return this;
         }
    @@ -5573,7 +4673,7 @@ public Builder setIconUrl(
          */
         public Builder clearIconUrl() {
           iconUrl_ = getDefaultInstance().getIconUrl();
    -      bitField0_ = (bitField0_ & ~0x00040000);
    +      bitField0_ = (bitField0_ & ~0x00004000);
           onChanged();
           return this;
         }
    @@ -5591,7 +4691,7 @@ public Builder setIconUrlBytes(
           if (value == null) { throw new NullPointerException(); }
           checkByteStringIsUtf8(value);
           iconUrl_ = value;
    -      bitField0_ |= 0x00040000;
    +      bitField0_ |= 0x00004000;
           onChanged();
           return this;
         }
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/AgentCardOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/AgentCardOrBuilder.java
    index 91ad7f3b4..8c31e3053 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/AgentCardOrBuilder.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/AgentCardOrBuilder.java
    @@ -12,35 +12,56 @@ public interface AgentCardOrBuilder extends
     
       /**
        * 
    -   * The version of the A2A protocol this agent supports.
    -   * Default: "1.0"
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
        * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return Whether the protocolVersion field is set. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return A list containing the protocolVersions. */ - boolean hasProtocolVersion(); + java.util.List + getProtocolVersionsList(); + /** + *
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
    +   * 
    + * + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return The count of protocolVersions. + */ + int getProtocolVersionsCount(); /** *
    -   * The version of the A2A protocol this agent supports.
    -   * Default: "1.0"
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
        * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return The protocolVersion. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index of the element to return. + * @return The protocolVersions at the given index. */ - java.lang.String getProtocolVersion(); + java.lang.String getProtocolVersions(int index); /** *
    -   * The version of the A2A protocol this agent supports.
    -   * Default: "1.0"
    +   * The versions of the A2A protocol this agent supports.
    +   * For stable versions (1.x+), list only the latest supported minor version per major version.
    +   * For legacy experimental versions (0.x), explicitly list each supported version.
    +   * Default: ["1.0"]
        * 
    * - * optional string protocol_version = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for protocolVersion. + * repeated string protocol_versions = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param index The index of the value to return. + * @return The bytes of the protocolVersions at the given index. */ com.google.protobuf.ByteString - getProtocolVersionBytes(); + getProtocolVersionsBytes(int index); /** *
    @@ -93,7 +114,7 @@ public interface AgentCardOrBuilder extends
        * Ordered list of supported interfaces. First entry is preferred.
        * 
    * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ java.util.List getSupportedInterfacesList(); @@ -102,7 +123,7 @@ public interface AgentCardOrBuilder extends * Ordered list of supported interfaces. First entry is preferred. *
    * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ io.a2a.grpc.AgentInterface getSupportedInterfaces(int index); /** @@ -110,7 +131,7 @@ public interface AgentCardOrBuilder extends * Ordered list of supported interfaces. First entry is preferred. *
    * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ int getSupportedInterfacesCount(); /** @@ -118,7 +139,7 @@ public interface AgentCardOrBuilder extends * Ordered list of supported interfaces. First entry is preferred. *
    * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ java.util.List getSupportedInterfacesOrBuilderList(); @@ -127,125 +148,11 @@ public interface AgentCardOrBuilder extends * Ordered list of supported interfaces. First entry is preferred. *
    * - * repeated .a2a.v1.AgentInterface supported_interfaces = 19; + * repeated .a2a.v1.AgentInterface supported_interfaces = 19 [(.google.api.field_behavior) = REQUIRED]; */ io.a2a.grpc.AgentInterfaceOrBuilder getSupportedInterfacesOrBuilder( int index); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return Whether the url field is set. - */ - @java.lang.Deprecated boolean hasUrl(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return The url. - */ - @java.lang.Deprecated java.lang.String getUrl(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string url = 3 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.url is deprecated. - * See a2a.proto;l=426 - * @return The bytes for url. - */ - @java.lang.Deprecated com.google.protobuf.ByteString - getUrlBytes(); - - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return Whether the preferredTransport field is set. - */ - @java.lang.Deprecated boolean hasPreferredTransport(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return The preferredTransport. - */ - @java.lang.Deprecated java.lang.String getPreferredTransport(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * optional string preferred_transport = 14 [deprecated = true]; - * @deprecated a2a.v1.AgentCard.preferred_transport is deprecated. - * See a2a.proto;l=428 - * @return The bytes for preferredTransport. - */ - @java.lang.Deprecated com.google.protobuf.ByteString - getPreferredTransportBytes(); - - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Deprecated java.util.List - getAdditionalInterfacesList(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Deprecated io.a2a.grpc.AgentInterface getAdditionalInterfaces(int index); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Deprecated int getAdditionalInterfacesCount(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Deprecated java.util.List - getAdditionalInterfacesOrBuilderList(); - /** - *
    -   * DEPRECATED: Use 'supported_interfaces' instead.
    -   * 
    - * - * repeated .a2a.v1.AgentInterface additional_interfaces = 15 [deprecated = true]; - */ - @java.lang.Deprecated io.a2a.grpc.AgentInterfaceOrBuilder getAdditionalInterfacesOrBuilder( - int index); - /** *
        * The service provider of the agent.
    @@ -598,25 +505,6 @@ io.a2a.grpc.SecurityOrBuilder getSecurityOrBuilder(
       io.a2a.grpc.AgentSkillOrBuilder getSkillsOrBuilder(
           int index);
     
    -  /**
    -   * 
    -   * Whether the agent supports providing an extended agent card when authenticated.
    -   * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return Whether the supportsExtendedAgentCard field is set. - */ - boolean hasSupportsExtendedAgentCard(); - /** - *
    -   * Whether the agent supports providing an extended agent card when authenticated.
    -   * 
    - * - * optional bool supports_extended_agent_card = 13; - * @return The supportsExtendedAgentCard. - */ - boolean getSupportsExtendedAgentCard(); - /** *
        * JSON Web Signatures computed for this AgentCard.
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlow.java b/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlow.java
    index 9bbc4a253..06b7b8f41 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlow.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlow.java
    @@ -299,6 +299,22 @@ public java.lang.String getScopesOrThrow(
         return map.get(key);
       }
     
    +  public static final int PKCE_REQUIRED_FIELD_NUMBER = 5;
    +  private boolean pkceRequired_ = false;
    +  /**
    +   * 
    +   * Indicates if PKCE (RFC 7636) is required for this flow.
    +   * PKCE should always be used for public clients and is recommended for all clients.
    +   * 
    + * + * bool pkce_required = 5; + * @return The pkceRequired. + */ + @java.lang.Override + public boolean getPkceRequired() { + return pkceRequired_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { @@ -328,6 +344,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) internalGetScopes(), ScopesDefaultEntryHolder.defaultEntry, 4); + if (pkceRequired_ != false) { + output.writeBool(5, pkceRequired_); + } getUnknownFields().writeTo(output); } @@ -356,6 +375,10 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, scopes__); } + if (pkceRequired_ != false) { + size += com.google.protobuf.CodedOutputStream + .computeBoolSize(5, pkceRequired_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -379,6 +402,8 @@ public boolean equals(final java.lang.Object obj) { .equals(other.getRefreshUrl())) return false; if (!internalGetScopes().equals( other.internalGetScopes())) return false; + if (getPkceRequired() + != other.getPkceRequired()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -400,6 +425,9 @@ public int hashCode() { hash = (37 * hash) + SCOPES_FIELD_NUMBER; hash = (53 * hash) + internalGetScopes().hashCode(); } + hash = (37 * hash) + PKCE_REQUIRED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( + getPkceRequired()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -562,6 +590,7 @@ public Builder clear() { tokenUrl_ = ""; refreshUrl_ = ""; internalGetMutableScopes().clear(); + pkceRequired_ = false; return this; } @@ -608,6 +637,9 @@ private void buildPartial0(io.a2a.grpc.AuthorizationCodeOAuthFlow result) { result.scopes_ = internalGetScopes(); result.scopes_.makeImmutable(); } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.pkceRequired_ = pkceRequired_; + } } @java.lang.Override @@ -640,6 +672,9 @@ public Builder mergeFrom(io.a2a.grpc.AuthorizationCodeOAuthFlow other) { internalGetMutableScopes().mergeFrom( other.internalGetScopes()); bitField0_ |= 0x00000008; + if (other.getPkceRequired() != false) { + setPkceRequired(other.getPkceRequired()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -690,6 +725,11 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 40: { + pkceRequired_ = input.readBool(); + bitField0_ |= 0x00000010; + break; + } // case 40 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag @@ -1138,6 +1178,53 @@ public Builder putAllScopes( return this; } + private boolean pkceRequired_ ; + /** + *
    +     * Indicates if PKCE (RFC 7636) is required for this flow.
    +     * PKCE should always be used for public clients and is recommended for all clients.
    +     * 
    + * + * bool pkce_required = 5; + * @return The pkceRequired. + */ + @java.lang.Override + public boolean getPkceRequired() { + return pkceRequired_; + } + /** + *
    +     * Indicates if PKCE (RFC 7636) is required for this flow.
    +     * PKCE should always be used for public clients and is recommended for all clients.
    +     * 
    + * + * bool pkce_required = 5; + * @param value The pkceRequired to set. + * @return This builder for chaining. + */ + public Builder setPkceRequired(boolean value) { + + pkceRequired_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + /** + *
    +     * Indicates if PKCE (RFC 7636) is required for this flow.
    +     * PKCE should always be used for public clients and is recommended for all clients.
    +     * 
    + * + * bool pkce_required = 5; + * @return This builder for chaining. + */ + public Builder clearPkceRequired() { + bitField0_ = (bitField0_ & ~0x00000010); + pkceRequired_ = false; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:a2a.v1.AuthorizationCodeOAuthFlow) } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlowOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlowOrBuilder.java index b50acbd01..5dd2d393d 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlowOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/AuthorizationCodeOAuthFlowOrBuilder.java @@ -123,4 +123,15 @@ java.lang.String getScopesOrDefault( */ java.lang.String getScopesOrThrow( java.lang.String key); + + /** + *
    +   * Indicates if PKCE (RFC 7636) is required for this flow.
    +   * PKCE should always be used for public clients and is recommended for all clients.
    +   * 
    + * + * bool pkce_required = 5; + * @return The pkceRequired. + */ + boolean getPkceRequired(); } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/PasswordOAuthFlow.java b/spec-grpc/src/main/java/io/a2a/grpc/DeviceCodeOAuthFlow.java similarity index 69% rename from spec-grpc/src/main/java/io/a2a/grpc/PasswordOAuthFlow.java rename to spec-grpc/src/main/java/io/a2a/grpc/DeviceCodeOAuthFlow.java index 2f21f9789..701371c2b 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/PasswordOAuthFlow.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/DeviceCodeOAuthFlow.java @@ -7,17 +7,19 @@ /** *
    - * --8<-- [start:PasswordOAuthFlow]
    - * Defines configuration details for the OAuth 2.0 Resource Owner Password flow.
    + * --8<-- [start:DeviceCodeOAuthFlow]
    + * Defines configuration details for the OAuth 2.0 Device Code flow (RFC 8628).
    + * This flow is designed for input-constrained devices such as IoT devices,
    + * and CLI tools where the user authenticates on a separate device.
      * 
    * - * Protobuf type {@code a2a.v1.PasswordOAuthFlow} + * Protobuf type {@code a2a.v1.DeviceCodeOAuthFlow} */ @com.google.protobuf.Generated -public final class PasswordOAuthFlow extends +public final class DeviceCodeOAuthFlow extends com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:a2a.v1.PasswordOAuthFlow) - PasswordOAuthFlowOrBuilder { + // @@protoc_insertion_point(message_implements:a2a.v1.DeviceCodeOAuthFlow) + DeviceCodeOAuthFlowOrBuilder { private static final long serialVersionUID = 0L; static { com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( @@ -26,20 +28,21 @@ public final class PasswordOAuthFlow extends /* minor= */ 33, /* patch= */ 1, /* suffix= */ "", - "PasswordOAuthFlow"); + "DeviceCodeOAuthFlow"); } - // Use PasswordOAuthFlow.newBuilder() to construct. - private PasswordOAuthFlow(com.google.protobuf.GeneratedMessage.Builder builder) { + // Use DeviceCodeOAuthFlow.newBuilder() to construct. + private DeviceCodeOAuthFlow(com.google.protobuf.GeneratedMessage.Builder builder) { super(builder); } - private PasswordOAuthFlow() { + private DeviceCodeOAuthFlow() { + deviceAuthorizationUrl_ = ""; tokenUrl_ = ""; refreshUrl_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_PasswordOAuthFlow_descriptor; + return io.a2a.grpc.A2A.internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor; } @SuppressWarnings({"rawtypes"}) @@ -47,7 +50,7 @@ private PasswordOAuthFlow() { protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { - case 3: + case 4: return internalGetScopes(); default: throw new RuntimeException( @@ -57,12 +60,59 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_PasswordOAuthFlow_fieldAccessorTable + return io.a2a.grpc.A2A.internal_static_a2a_v1_DeviceCodeOAuthFlow_fieldAccessorTable .ensureFieldAccessorsInitialized( - io.a2a.grpc.PasswordOAuthFlow.class, io.a2a.grpc.PasswordOAuthFlow.Builder.class); + io.a2a.grpc.DeviceCodeOAuthFlow.class, io.a2a.grpc.DeviceCodeOAuthFlow.Builder.class); } - public static final int TOKEN_URL_FIELD_NUMBER = 1; + public static final int DEVICE_AUTHORIZATION_URL_FIELD_NUMBER = 1; + @SuppressWarnings("serial") + private volatile java.lang.Object deviceAuthorizationUrl_ = ""; + /** + *
    +   * The device authorization endpoint URL.
    +   * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The deviceAuthorizationUrl. + */ + @java.lang.Override + public java.lang.String getDeviceAuthorizationUrl() { + java.lang.Object ref = deviceAuthorizationUrl_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + deviceAuthorizationUrl_ = s; + return s; + } + } + /** + *
    +   * The device authorization endpoint URL.
    +   * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The bytes for deviceAuthorizationUrl. + */ + @java.lang.Override + public com.google.protobuf.ByteString + getDeviceAuthorizationUrlBytes() { + java.lang.Object ref = deviceAuthorizationUrl_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + deviceAuthorizationUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TOKEN_URL_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object tokenUrl_ = ""; /** @@ -70,7 +120,7 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl * The token URL to be used for this flow. *
    * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return The tokenUrl. */ @java.lang.Override @@ -91,7 +141,7 @@ public java.lang.String getTokenUrl() { * The token URL to be used for this flow. *
    * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return The bytes for tokenUrl. */ @java.lang.Override @@ -109,7 +159,7 @@ public java.lang.String getTokenUrl() { } } - public static final int REFRESH_URL_FIELD_NUMBER = 2; + public static final int REFRESH_URL_FIELD_NUMBER = 3; @SuppressWarnings("serial") private volatile java.lang.Object refreshUrl_ = ""; /** @@ -117,7 +167,7 @@ public java.lang.String getTokenUrl() { * The URL to be used for obtaining refresh tokens. *
    * - * string refresh_url = 2; + * string refresh_url = 3; * @return The refreshUrl. */ @java.lang.Override @@ -138,7 +188,7 @@ public java.lang.String getRefreshUrl() { * The URL to be used for obtaining refresh tokens. *
    * - * string refresh_url = 2; + * string refresh_url = 3; * @return The bytes for refreshUrl. */ @java.lang.Override @@ -156,13 +206,13 @@ public java.lang.String getRefreshUrl() { } } - public static final int SCOPES_FIELD_NUMBER = 3; + public static final int SCOPES_FIELD_NUMBER = 4; private static final class ScopesDefaultEntryHolder { static final com.google.protobuf.MapEntry< java.lang.String, java.lang.String> defaultEntry = com.google.protobuf.MapEntry .newDefaultInstance( - io.a2a.grpc.A2A.internal_static_a2a_v1_PasswordOAuthFlow_ScopesEntry_descriptor, + io.a2a.grpc.A2A.internal_static_a2a_v1_DeviceCodeOAuthFlow_ScopesEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.STRING, @@ -187,7 +237,7 @@ public int getScopesCount() { * The available scopes for the OAuth2 security scheme. *
    * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public boolean containsScopes( @@ -208,7 +258,7 @@ public java.util.Map getScopes() { * The available scopes for the OAuth2 security scheme. *
    * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public java.util.Map getScopesMap() { @@ -219,7 +269,7 @@ public java.util.Map getScopesMap() { * The available scopes for the OAuth2 security scheme. *
    * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public /* nullable */ @@ -237,7 +287,7 @@ java.lang.String getScopesOrDefault( * The available scopes for the OAuth2 security scheme. *
    * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public java.lang.String getScopesOrThrow( @@ -265,18 +315,21 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(deviceAuthorizationUrl_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, deviceAuthorizationUrl_); + } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(tokenUrl_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 1, tokenUrl_); + com.google.protobuf.GeneratedMessage.writeString(output, 2, tokenUrl_); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(refreshUrl_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 2, refreshUrl_); + com.google.protobuf.GeneratedMessage.writeString(output, 3, refreshUrl_); } com.google.protobuf.GeneratedMessage .serializeStringMapTo( output, internalGetScopes(), ScopesDefaultEntryHolder.defaultEntry, - 3); + 4); getUnknownFields().writeTo(output); } @@ -286,11 +339,14 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(deviceAuthorizationUrl_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, deviceAuthorizationUrl_); + } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(tokenUrl_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(1, tokenUrl_); + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, tokenUrl_); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(refreshUrl_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(2, refreshUrl_); + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, refreshUrl_); } for (java.util.Map.Entry entry : internalGetScopes().getMap().entrySet()) { @@ -300,7 +356,7 @@ public int getSerializedSize() { .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, scopes__); + .computeMessageSize(4, scopes__); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -312,11 +368,13 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof io.a2a.grpc.PasswordOAuthFlow)) { + if (!(obj instanceof io.a2a.grpc.DeviceCodeOAuthFlow)) { return super.equals(obj); } - io.a2a.grpc.PasswordOAuthFlow other = (io.a2a.grpc.PasswordOAuthFlow) obj; + io.a2a.grpc.DeviceCodeOAuthFlow other = (io.a2a.grpc.DeviceCodeOAuthFlow) obj; + if (!getDeviceAuthorizationUrl() + .equals(other.getDeviceAuthorizationUrl())) return false; if (!getTokenUrl() .equals(other.getTokenUrl())) return false; if (!getRefreshUrl() @@ -334,6 +392,8 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DEVICE_AUTHORIZATION_URL_FIELD_NUMBER; + hash = (53 * hash) + getDeviceAuthorizationUrl().hashCode(); hash = (37 * hash) + TOKEN_URL_FIELD_NUMBER; hash = (53 * hash) + getTokenUrl().hashCode(); hash = (37 * hash) + REFRESH_URL_FIELD_NUMBER; @@ -347,44 +407,44 @@ public int hashCode() { return hash; } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom(byte[] data) + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom(java.io.InputStream input) + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -392,26 +452,26 @@ public static io.a2a.grpc.PasswordOAuthFlow parseFrom( .parseWithIOException(PARSER, input, extensionRegistry); } - public static io.a2a.grpc.PasswordOAuthFlow parseDelimitedFrom(java.io.InputStream input) + public static io.a2a.grpc.DeviceCodeOAuthFlow parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input); } - public static io.a2a.grpc.PasswordOAuthFlow parseDelimitedFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } - public static io.a2a.grpc.PasswordOAuthFlow parseFrom( + public static io.a2a.grpc.DeviceCodeOAuthFlow parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -424,7 +484,7 @@ public static io.a2a.grpc.PasswordOAuthFlow parseFrom( public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(io.a2a.grpc.PasswordOAuthFlow prototype) { + public static Builder newBuilder(io.a2a.grpc.DeviceCodeOAuthFlow prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override @@ -441,26 +501,28 @@ protected Builder newBuilderForType( } /** *
    -   * --8<-- [start:PasswordOAuthFlow]
    -   * Defines configuration details for the OAuth 2.0 Resource Owner Password flow.
    +   * --8<-- [start:DeviceCodeOAuthFlow]
    +   * Defines configuration details for the OAuth 2.0 Device Code flow (RFC 8628).
    +   * This flow is designed for input-constrained devices such as IoT devices,
    +   * and CLI tools where the user authenticates on a separate device.
        * 
    * - * Protobuf type {@code a2a.v1.PasswordOAuthFlow} + * Protobuf type {@code a2a.v1.DeviceCodeOAuthFlow} */ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder implements - // @@protoc_insertion_point(builder_implements:a2a.v1.PasswordOAuthFlow) - io.a2a.grpc.PasswordOAuthFlowOrBuilder { + // @@protoc_insertion_point(builder_implements:a2a.v1.DeviceCodeOAuthFlow) + io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_PasswordOAuthFlow_descriptor; + return io.a2a.grpc.A2A.internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor; } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { - case 3: + case 4: return internalGetScopes(); default: throw new RuntimeException( @@ -471,7 +533,7 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( int number) { switch (number) { - case 3: + case 4: return internalGetMutableScopes(); default: throw new RuntimeException( @@ -481,12 +543,12 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFi @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_PasswordOAuthFlow_fieldAccessorTable + return io.a2a.grpc.A2A.internal_static_a2a_v1_DeviceCodeOAuthFlow_fieldAccessorTable .ensureFieldAccessorsInitialized( - io.a2a.grpc.PasswordOAuthFlow.class, io.a2a.grpc.PasswordOAuthFlow.Builder.class); + io.a2a.grpc.DeviceCodeOAuthFlow.class, io.a2a.grpc.DeviceCodeOAuthFlow.Builder.class); } - // Construct using io.a2a.grpc.PasswordOAuthFlow.newBuilder() + // Construct using io.a2a.grpc.DeviceCodeOAuthFlow.newBuilder() private Builder() { } @@ -500,6 +562,7 @@ private Builder( public Builder clear() { super.clear(); bitField0_ = 0; + deviceAuthorizationUrl_ = ""; tokenUrl_ = ""; refreshUrl_ = ""; internalGetMutableScopes().clear(); @@ -509,17 +572,17 @@ public Builder clear() { @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_PasswordOAuthFlow_descriptor; + return io.a2a.grpc.A2A.internal_static_a2a_v1_DeviceCodeOAuthFlow_descriptor; } @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlow getDefaultInstanceForType() { - return io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); + public io.a2a.grpc.DeviceCodeOAuthFlow getDefaultInstanceForType() { + return io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlow build() { - io.a2a.grpc.PasswordOAuthFlow result = buildPartial(); + public io.a2a.grpc.DeviceCodeOAuthFlow build() { + io.a2a.grpc.DeviceCodeOAuthFlow result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } @@ -527,22 +590,25 @@ public io.a2a.grpc.PasswordOAuthFlow build() { } @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlow buildPartial() { - io.a2a.grpc.PasswordOAuthFlow result = new io.a2a.grpc.PasswordOAuthFlow(this); + public io.a2a.grpc.DeviceCodeOAuthFlow buildPartial() { + io.a2a.grpc.DeviceCodeOAuthFlow result = new io.a2a.grpc.DeviceCodeOAuthFlow(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } - private void buildPartial0(io.a2a.grpc.PasswordOAuthFlow result) { + private void buildPartial0(io.a2a.grpc.DeviceCodeOAuthFlow result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { - result.tokenUrl_ = tokenUrl_; + result.deviceAuthorizationUrl_ = deviceAuthorizationUrl_; } if (((from_bitField0_ & 0x00000002) != 0)) { - result.refreshUrl_ = refreshUrl_; + result.tokenUrl_ = tokenUrl_; } if (((from_bitField0_ & 0x00000004) != 0)) { + result.refreshUrl_ = refreshUrl_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { result.scopes_ = internalGetScopes(); result.scopes_.makeImmutable(); } @@ -550,29 +616,34 @@ private void buildPartial0(io.a2a.grpc.PasswordOAuthFlow result) { @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.a2a.grpc.PasswordOAuthFlow) { - return mergeFrom((io.a2a.grpc.PasswordOAuthFlow)other); + if (other instanceof io.a2a.grpc.DeviceCodeOAuthFlow) { + return mergeFrom((io.a2a.grpc.DeviceCodeOAuthFlow)other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(io.a2a.grpc.PasswordOAuthFlow other) { - if (other == io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance()) return this; + public Builder mergeFrom(io.a2a.grpc.DeviceCodeOAuthFlow other) { + if (other == io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance()) return this; + if (!other.getDeviceAuthorizationUrl().isEmpty()) { + deviceAuthorizationUrl_ = other.deviceAuthorizationUrl_; + bitField0_ |= 0x00000001; + onChanged(); + } if (!other.getTokenUrl().isEmpty()) { tokenUrl_ = other.tokenUrl_; - bitField0_ |= 0x00000001; + bitField0_ |= 0x00000002; onChanged(); } if (!other.getRefreshUrl().isEmpty()) { refreshUrl_ = other.refreshUrl_; - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); } internalGetMutableScopes().mergeFrom( other.internalGetScopes()); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -600,24 +671,29 @@ public Builder mergeFrom( done = true; break; case 10: { - tokenUrl_ = input.readStringRequireUtf8(); + deviceAuthorizationUrl_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { - refreshUrl_ = input.readStringRequireUtf8(); + tokenUrl_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 case 26: { + refreshUrl_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: { com.google.protobuf.MapEntry scopes__ = input.readMessage( ScopesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); internalGetMutableScopes().getMutableMap().put( scopes__.getKey(), scopes__.getValue()); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; break; - } // case 26 + } // case 34 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag @@ -635,13 +711,105 @@ public Builder mergeFrom( } private int bitField0_; + private java.lang.Object deviceAuthorizationUrl_ = ""; + /** + *
    +     * The device authorization endpoint URL.
    +     * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The deviceAuthorizationUrl. + */ + public java.lang.String getDeviceAuthorizationUrl() { + java.lang.Object ref = deviceAuthorizationUrl_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + deviceAuthorizationUrl_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + *
    +     * The device authorization endpoint URL.
    +     * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The bytes for deviceAuthorizationUrl. + */ + public com.google.protobuf.ByteString + getDeviceAuthorizationUrlBytes() { + java.lang.Object ref = deviceAuthorizationUrl_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + deviceAuthorizationUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + *
    +     * The device authorization endpoint URL.
    +     * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param value The deviceAuthorizationUrl to set. + * @return This builder for chaining. + */ + public Builder setDeviceAuthorizationUrl( + java.lang.String value) { + if (value == null) { throw new NullPointerException(); } + deviceAuthorizationUrl_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + /** + *
    +     * The device authorization endpoint URL.
    +     * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return This builder for chaining. + */ + public Builder clearDeviceAuthorizationUrl() { + deviceAuthorizationUrl_ = getDefaultInstance().getDeviceAuthorizationUrl(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + *
    +     * The device authorization endpoint URL.
    +     * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param value The bytes for deviceAuthorizationUrl to set. + * @return This builder for chaining. + */ + public Builder setDeviceAuthorizationUrlBytes( + com.google.protobuf.ByteString value) { + if (value == null) { throw new NullPointerException(); } + checkByteStringIsUtf8(value); + deviceAuthorizationUrl_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + private java.lang.Object tokenUrl_ = ""; /** *
          * The token URL to be used for this flow.
          * 
    * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return The tokenUrl. */ public java.lang.String getTokenUrl() { @@ -661,7 +829,7 @@ public java.lang.String getTokenUrl() { * The token URL to be used for this flow. * * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return The bytes for tokenUrl. */ public com.google.protobuf.ByteString @@ -682,7 +850,7 @@ public java.lang.String getTokenUrl() { * The token URL to be used for this flow. * * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @param value The tokenUrl to set. * @return This builder for chaining. */ @@ -690,7 +858,7 @@ public Builder setTokenUrl( java.lang.String value) { if (value == null) { throw new NullPointerException(); } tokenUrl_ = value; - bitField0_ |= 0x00000001; + bitField0_ |= 0x00000002; onChanged(); return this; } @@ -699,12 +867,12 @@ public Builder setTokenUrl( * The token URL to be used for this flow. * * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return This builder for chaining. */ public Builder clearTokenUrl() { tokenUrl_ = getDefaultInstance().getTokenUrl(); - bitField0_ = (bitField0_ & ~0x00000001); + bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } @@ -713,7 +881,7 @@ public Builder clearTokenUrl() { * The token URL to be used for this flow. * * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @param value The bytes for tokenUrl to set. * @return This builder for chaining. */ @@ -722,7 +890,7 @@ public Builder setTokenUrlBytes( if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); tokenUrl_ = value; - bitField0_ |= 0x00000001; + bitField0_ |= 0x00000002; onChanged(); return this; } @@ -733,7 +901,7 @@ public Builder setTokenUrlBytes( * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @return The refreshUrl. */ public java.lang.String getRefreshUrl() { @@ -753,7 +921,7 @@ public java.lang.String getRefreshUrl() { * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @return The bytes for refreshUrl. */ public com.google.protobuf.ByteString @@ -774,7 +942,7 @@ public java.lang.String getRefreshUrl() { * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @param value The refreshUrl to set. * @return This builder for chaining. */ @@ -782,7 +950,7 @@ public Builder setRefreshUrl( java.lang.String value) { if (value == null) { throw new NullPointerException(); } refreshUrl_ = value; - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return this; } @@ -791,12 +959,12 @@ public Builder setRefreshUrl( * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @return This builder for chaining. */ public Builder clearRefreshUrl() { refreshUrl_ = getDefaultInstance().getRefreshUrl(); - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } @@ -805,7 +973,7 @@ public Builder clearRefreshUrl() { * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @param value The bytes for refreshUrl to set. * @return This builder for chaining. */ @@ -814,7 +982,7 @@ public Builder setRefreshUrlBytes( if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); refreshUrl_ = value; - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return this; } @@ -838,7 +1006,7 @@ public Builder setRefreshUrlBytes( if (!scopes_.isMutable()) { scopes_ = scopes_.copy(); } - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return scopes_; } @@ -850,7 +1018,7 @@ public int getScopesCount() { * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public boolean containsScopes( @@ -871,7 +1039,7 @@ public java.util.Map getScopes() { * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public java.util.Map getScopesMap() { @@ -882,7 +1050,7 @@ public java.util.Map getScopesMap() { * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public /* nullable */ @@ -900,7 +1068,7 @@ java.lang.String getScopesOrDefault( * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override public java.lang.String getScopesOrThrow( @@ -914,7 +1082,7 @@ public java.lang.String getScopesOrThrow( return map.get(key); } public Builder clearScopes() { - bitField0_ = (bitField0_ & ~0x00000004); + bitField0_ = (bitField0_ & ~0x00000008); internalGetMutableScopes().getMutableMap() .clear(); return this; @@ -924,7 +1092,7 @@ public Builder clearScopes() { * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ public Builder removeScopes( java.lang.String key) { @@ -939,7 +1107,7 @@ public Builder removeScopes( @java.lang.Deprecated public java.util.Map getMutableScopes() { - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; return internalGetMutableScopes().getMutableMap(); } /** @@ -947,7 +1115,7 @@ public Builder removeScopes( * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ public Builder putScopes( java.lang.String key, @@ -956,7 +1124,7 @@ public Builder putScopes( if (value == null) { throw new NullPointerException("map value"); } internalGetMutableScopes().getMutableMap() .put(key, value); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; return this; } /** @@ -964,33 +1132,33 @@ public Builder putScopes( * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ public Builder putAllScopes( java.util.Map values) { internalGetMutableScopes().getMutableMap() .putAll(values); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; return this; } - // @@protoc_insertion_point(builder_scope:a2a.v1.PasswordOAuthFlow) + // @@protoc_insertion_point(builder_scope:a2a.v1.DeviceCodeOAuthFlow) } - // @@protoc_insertion_point(class_scope:a2a.v1.PasswordOAuthFlow) - private static final io.a2a.grpc.PasswordOAuthFlow DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:a2a.v1.DeviceCodeOAuthFlow) + private static final io.a2a.grpc.DeviceCodeOAuthFlow DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new io.a2a.grpc.PasswordOAuthFlow(); + DEFAULT_INSTANCE = new io.a2a.grpc.DeviceCodeOAuthFlow(); } - public static io.a2a.grpc.PasswordOAuthFlow getDefaultInstance() { + public static io.a2a.grpc.DeviceCodeOAuthFlow getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override - public PasswordOAuthFlow parsePartialFrom( + public DeviceCodeOAuthFlow parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -1009,17 +1177,17 @@ public PasswordOAuthFlow parsePartialFrom( } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlow getDefaultInstanceForType() { + public io.a2a.grpc.DeviceCodeOAuthFlow getDefaultInstanceForType() { return DEFAULT_INSTANCE; } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/PasswordOAuthFlowOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/DeviceCodeOAuthFlowOrBuilder.java similarity index 63% rename from spec-grpc/src/main/java/io/a2a/grpc/PasswordOAuthFlowOrBuilder.java rename to spec-grpc/src/main/java/io/a2a/grpc/DeviceCodeOAuthFlowOrBuilder.java index 1b0aeeac0..761e2a6db 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/PasswordOAuthFlowOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/DeviceCodeOAuthFlowOrBuilder.java @@ -6,16 +6,36 @@ package io.a2a.grpc; @com.google.protobuf.Generated -public interface PasswordOAuthFlowOrBuilder extends - // @@protoc_insertion_point(interface_extends:a2a.v1.PasswordOAuthFlow) +public interface DeviceCodeOAuthFlowOrBuilder extends + // @@protoc_insertion_point(interface_extends:a2a.v1.DeviceCodeOAuthFlow) com.google.protobuf.MessageOrBuilder { + /** + *
    +   * The device authorization endpoint URL.
    +   * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The deviceAuthorizationUrl. + */ + java.lang.String getDeviceAuthorizationUrl(); + /** + *
    +   * The device authorization endpoint URL.
    +   * 
    + * + * string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The bytes for deviceAuthorizationUrl. + */ + com.google.protobuf.ByteString + getDeviceAuthorizationUrlBytes(); + /** *
        * The token URL to be used for this flow.
        * 
    * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return The tokenUrl. */ java.lang.String getTokenUrl(); @@ -24,7 +44,7 @@ public interface PasswordOAuthFlowOrBuilder extends * The token URL to be used for this flow. * * - * string token_url = 1 [(.google.api.field_behavior) = REQUIRED]; + * string token_url = 2 [(.google.api.field_behavior) = REQUIRED]; * @return The bytes for tokenUrl. */ com.google.protobuf.ByteString @@ -35,7 +55,7 @@ public interface PasswordOAuthFlowOrBuilder extends * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @return The refreshUrl. */ java.lang.String getRefreshUrl(); @@ -44,7 +64,7 @@ public interface PasswordOAuthFlowOrBuilder extends * The URL to be used for obtaining refresh tokens. * * - * string refresh_url = 2; + * string refresh_url = 3; * @return The bytes for refreshUrl. */ com.google.protobuf.ByteString @@ -55,7 +75,7 @@ public interface PasswordOAuthFlowOrBuilder extends * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ int getScopesCount(); /** @@ -63,7 +83,7 @@ public interface PasswordOAuthFlowOrBuilder extends * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ boolean containsScopes( java.lang.String key); @@ -78,7 +98,7 @@ boolean containsScopes( * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ java.util.Map getScopesMap(); @@ -87,7 +107,7 @@ boolean containsScopes( * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ /* nullable */ java.lang.String getScopesOrDefault( @@ -99,7 +119,7 @@ java.lang.String getScopesOrDefault( * The available scopes for the OAuth2 security scheme. * * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; + * map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED]; */ java.lang.String getScopesOrThrow( java.lang.String key); diff --git a/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequest.java b/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequest.java index 2322a9f8b..33395ab8d 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequest.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequest.java @@ -151,7 +151,10 @@ public java.lang.String getName() { private int historyLength_ = 0; /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve. An
    +   * unset value means the client does not impose any limit. A value of zero is
    +   * a request to not include any messages. The server MUST NOT return more
    +   * messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 2; @@ -163,7 +166,10 @@ public boolean hasHistoryLength() { } /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve. An
    +   * unset value means the client does not impose any limit. A value of zero is
    +   * a request to not include any messages. The server MUST NOT return more
    +   * messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 2; @@ -720,7 +726,10 @@ public Builder setNameBytes( private int historyLength_ ; /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve. An
    +     * unset value means the client does not impose any limit. A value of zero is
    +     * a request to not include any messages. The server MUST NOT return more
    +     * messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 2; @@ -732,7 +741,10 @@ public boolean hasHistoryLength() { } /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve. An
    +     * unset value means the client does not impose any limit. A value of zero is
    +     * a request to not include any messages. The server MUST NOT return more
    +     * messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 2; @@ -744,7 +756,10 @@ public int getHistoryLength() { } /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve. An
    +     * unset value means the client does not impose any limit. A value of zero is
    +     * a request to not include any messages. The server MUST NOT return more
    +     * messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 2; @@ -760,7 +775,10 @@ public Builder setHistoryLength(int value) { } /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve. An
    +     * unset value means the client does not impose any limit. A value of zero is
    +     * a request to not include any messages. The server MUST NOT return more
    +     * messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 2; diff --git a/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequestOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequestOrBuilder.java index a17389884..1ef78600d 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequestOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/GetTaskRequestOrBuilder.java @@ -54,7 +54,10 @@ public interface GetTaskRequestOrBuilder extends /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve. An
    +   * unset value means the client does not impose any limit. A value of zero is
    +   * a request to not include any messages. The server MUST NOT return more
    +   * messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 2; @@ -63,7 +66,10 @@ public interface GetTaskRequestOrBuilder extends boolean hasHistoryLength(); /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve. An
    +   * unset value means the client does not impose any limit. A value of zero is
    +   * a request to not include any messages. The server MUST NOT return more
    +   * messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 2; diff --git a/spec-grpc/src/main/java/io/a2a/grpc/ImplicitOAuthFlow.java b/spec-grpc/src/main/java/io/a2a/grpc/ImplicitOAuthFlow.java deleted file mode 100644 index a7f186016..000000000 --- a/spec-grpc/src/main/java/io/a2a/grpc/ImplicitOAuthFlow.java +++ /dev/null @@ -1,1027 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// NO CHECKED-IN PROTOBUF GENCODE -// source: a2a.proto -// Protobuf Java Version: 4.33.1 - -package io.a2a.grpc; - -/** - *
    - * --8<-- [start:ImplicitOAuthFlow]
    - * Defines configuration details for the OAuth 2.0 Implicit flow.
    - * 
    - * - * Protobuf type {@code a2a.v1.ImplicitOAuthFlow} - */ -@com.google.protobuf.Generated -public final class ImplicitOAuthFlow extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:a2a.v1.ImplicitOAuthFlow) - ImplicitOAuthFlowOrBuilder { -private static final long serialVersionUID = 0L; - static { - com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( - com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, - /* major= */ 4, - /* minor= */ 33, - /* patch= */ 1, - /* suffix= */ "", - "ImplicitOAuthFlow"); - } - // Use ImplicitOAuthFlow.newBuilder() to construct. - private ImplicitOAuthFlow(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private ImplicitOAuthFlow() { - authorizationUrl_ = ""; - refreshUrl_ = ""; - } - - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_ImplicitOAuthFlow_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( - int number) { - switch (number) { - case 3: - return internalGetScopes(); - default: - throw new RuntimeException( - "Invalid map field number: " + number); - } - } - @java.lang.Override - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_ImplicitOAuthFlow_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.a2a.grpc.ImplicitOAuthFlow.class, io.a2a.grpc.ImplicitOAuthFlow.Builder.class); - } - - public static final int AUTHORIZATION_URL_FIELD_NUMBER = 1; - @SuppressWarnings("serial") - private volatile java.lang.Object authorizationUrl_ = ""; - /** - *
    -   * The authorization URL to be used for this flow.
    -   * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return The authorizationUrl. - */ - @java.lang.Override - public java.lang.String getAuthorizationUrl() { - java.lang.Object ref = authorizationUrl_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - authorizationUrl_ = s; - return s; - } - } - /** - *
    -   * The authorization URL to be used for this flow.
    -   * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for authorizationUrl. - */ - @java.lang.Override - public com.google.protobuf.ByteString - getAuthorizationUrlBytes() { - java.lang.Object ref = authorizationUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - authorizationUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REFRESH_URL_FIELD_NUMBER = 2; - @SuppressWarnings("serial") - private volatile java.lang.Object refreshUrl_ = ""; - /** - *
    -   * The URL to be used for obtaining refresh tokens.
    -   * 
    - * - * string refresh_url = 2; - * @return The refreshUrl. - */ - @java.lang.Override - public java.lang.String getRefreshUrl() { - java.lang.Object ref = refreshUrl_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - refreshUrl_ = s; - return s; - } - } - /** - *
    -   * The URL to be used for obtaining refresh tokens.
    -   * 
    - * - * string refresh_url = 2; - * @return The bytes for refreshUrl. - */ - @java.lang.Override - public com.google.protobuf.ByteString - getRefreshUrlBytes() { - java.lang.Object ref = refreshUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - refreshUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SCOPES_FIELD_NUMBER = 3; - private static final class ScopesDefaultEntryHolder { - static final com.google.protobuf.MapEntry< - java.lang.String, java.lang.String> defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - io.a2a.grpc.A2A.internal_static_a2a_v1_ImplicitOAuthFlow_ScopesEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - @SuppressWarnings("serial") - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> scopes_; - private com.google.protobuf.MapField - internalGetScopes() { - if (scopes_ == null) { - return com.google.protobuf.MapField.emptyMapField( - ScopesDefaultEntryHolder.defaultEntry); - } - return scopes_; - } - public int getScopesCount() { - return internalGetScopes().getMap().size(); - } - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public boolean containsScopes( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - return internalGetScopes().getMap().containsKey(key); - } - /** - * Use {@link #getScopesMap()} instead. - */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getScopes() { - return getScopesMap(); - } - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public java.util.Map getScopesMap() { - return internalGetScopes().getMap(); - } - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public /* nullable */ -java.lang.String getScopesOrDefault( - java.lang.String key, - /* nullable */ -java.lang.String defaultValue) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetScopes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public java.lang.String getScopesOrThrow( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetScopes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(authorizationUrl_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 1, authorizationUrl_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(refreshUrl_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 2, refreshUrl_); - } - com.google.protobuf.GeneratedMessage - .serializeStringMapTo( - output, - internalGetScopes(), - ScopesDefaultEntryHolder.defaultEntry, - 3); - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(authorizationUrl_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(1, authorizationUrl_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(refreshUrl_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(2, refreshUrl_); - } - for (java.util.Map.Entry entry - : internalGetScopes().getMap().entrySet()) { - com.google.protobuf.MapEntry - scopes__ = ScopesDefaultEntryHolder.defaultEntry.newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, scopes__); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof io.a2a.grpc.ImplicitOAuthFlow)) { - return super.equals(obj); - } - io.a2a.grpc.ImplicitOAuthFlow other = (io.a2a.grpc.ImplicitOAuthFlow) obj; - - if (!getAuthorizationUrl() - .equals(other.getAuthorizationUrl())) return false; - if (!getRefreshUrl() - .equals(other.getRefreshUrl())) return false; - if (!internalGetScopes().equals( - other.internalGetScopes())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + AUTHORIZATION_URL_FIELD_NUMBER; - hash = (53 * hash) + getAuthorizationUrl().hashCode(); - hash = (37 * hash) + REFRESH_URL_FIELD_NUMBER; - hash = (53 * hash) + getRefreshUrl().hashCode(); - if (!internalGetScopes().getMap().isEmpty()) { - hash = (37 * hash) + SCOPES_FIELD_NUMBER; - hash = (53 * hash) + internalGetScopes().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage - .parseWithIOException(PARSER, input); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public static io.a2a.grpc.ImplicitOAuthFlow parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage - .parseDelimitedWithIOException(PARSER, input); - } - - public static io.a2a.grpc.ImplicitOAuthFlow parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage - .parseWithIOException(PARSER, input); - } - public static io.a2a.grpc.ImplicitOAuthFlow parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage - .parseWithIOException(PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(io.a2a.grpc.ImplicitOAuthFlow prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
    -   * --8<-- [start:ImplicitOAuthFlow]
    -   * Defines configuration details for the OAuth 2.0 Implicit flow.
    -   * 
    - * - * Protobuf type {@code a2a.v1.ImplicitOAuthFlow} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder implements - // @@protoc_insertion_point(builder_implements:a2a.v1.ImplicitOAuthFlow) - io.a2a.grpc.ImplicitOAuthFlowOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_ImplicitOAuthFlow_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( - int number) { - switch (number) { - case 3: - return internalGetScopes(); - default: - throw new RuntimeException( - "Invalid map field number: " + number); - } - } - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( - int number) { - switch (number) { - case 3: - return internalGetMutableScopes(); - default: - throw new RuntimeException( - "Invalid map field number: " + number); - } - } - @java.lang.Override - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_ImplicitOAuthFlow_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.a2a.grpc.ImplicitOAuthFlow.class, io.a2a.grpc.ImplicitOAuthFlow.Builder.class); - } - - // Construct using io.a2a.grpc.ImplicitOAuthFlow.newBuilder() - private Builder() { - - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - - } - @java.lang.Override - public Builder clear() { - super.clear(); - bitField0_ = 0; - authorizationUrl_ = ""; - refreshUrl_ = ""; - internalGetMutableScopes().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return io.a2a.grpc.A2A.internal_static_a2a_v1_ImplicitOAuthFlow_descriptor; - } - - @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlow getDefaultInstanceForType() { - return io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); - } - - @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlow build() { - io.a2a.grpc.ImplicitOAuthFlow result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlow buildPartial() { - io.a2a.grpc.ImplicitOAuthFlow result = new io.a2a.grpc.ImplicitOAuthFlow(this); - if (bitField0_ != 0) { buildPartial0(result); } - onBuilt(); - return result; - } - - private void buildPartial0(io.a2a.grpc.ImplicitOAuthFlow result) { - int from_bitField0_ = bitField0_; - if (((from_bitField0_ & 0x00000001) != 0)) { - result.authorizationUrl_ = authorizationUrl_; - } - if (((from_bitField0_ & 0x00000002) != 0)) { - result.refreshUrl_ = refreshUrl_; - } - if (((from_bitField0_ & 0x00000004) != 0)) { - result.scopes_ = internalGetScopes(); - result.scopes_.makeImmutable(); - } - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.a2a.grpc.ImplicitOAuthFlow) { - return mergeFrom((io.a2a.grpc.ImplicitOAuthFlow)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.a2a.grpc.ImplicitOAuthFlow other) { - if (other == io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance()) return this; - if (!other.getAuthorizationUrl().isEmpty()) { - authorizationUrl_ = other.authorizationUrl_; - bitField0_ |= 0x00000001; - onChanged(); - } - if (!other.getRefreshUrl().isEmpty()) { - refreshUrl_ = other.refreshUrl_; - bitField0_ |= 0x00000002; - onChanged(); - } - internalGetMutableScopes().mergeFrom( - other.internalGetScopes()); - bitField0_ |= 0x00000004; - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: { - authorizationUrl_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00000001; - break; - } // case 10 - case 18: { - refreshUrl_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00000002; - break; - } // case 18 - case 26: { - com.google.protobuf.MapEntry - scopes__ = input.readMessage( - ScopesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - internalGetMutableScopes().getMutableMap().put( - scopes__.getKey(), scopes__.getValue()); - bitField0_ |= 0x00000004; - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - private int bitField0_; - - private java.lang.Object authorizationUrl_ = ""; - /** - *
    -     * The authorization URL to be used for this flow.
    -     * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return The authorizationUrl. - */ - public java.lang.String getAuthorizationUrl() { - java.lang.Object ref = authorizationUrl_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - authorizationUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
    -     * The authorization URL to be used for this flow.
    -     * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for authorizationUrl. - */ - public com.google.protobuf.ByteString - getAuthorizationUrlBytes() { - java.lang.Object ref = authorizationUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - authorizationUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
    -     * The authorization URL to be used for this flow.
    -     * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param value The authorizationUrl to set. - * @return This builder for chaining. - */ - public Builder setAuthorizationUrl( - java.lang.String value) { - if (value == null) { throw new NullPointerException(); } - authorizationUrl_ = value; - bitField0_ |= 0x00000001; - onChanged(); - return this; - } - /** - *
    -     * The authorization URL to be used for this flow.
    -     * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return This builder for chaining. - */ - public Builder clearAuthorizationUrl() { - authorizationUrl_ = getDefaultInstance().getAuthorizationUrl(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - *
    -     * The authorization URL to be used for this flow.
    -     * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param value The bytes for authorizationUrl to set. - * @return This builder for chaining. - */ - public Builder setAuthorizationUrlBytes( - com.google.protobuf.ByteString value) { - if (value == null) { throw new NullPointerException(); } - checkByteStringIsUtf8(value); - authorizationUrl_ = value; - bitField0_ |= 0x00000001; - onChanged(); - return this; - } - - private java.lang.Object refreshUrl_ = ""; - /** - *
    -     * The URL to be used for obtaining refresh tokens.
    -     * 
    - * - * string refresh_url = 2; - * @return The refreshUrl. - */ - public java.lang.String getRefreshUrl() { - java.lang.Object ref = refreshUrl_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - refreshUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
    -     * The URL to be used for obtaining refresh tokens.
    -     * 
    - * - * string refresh_url = 2; - * @return The bytes for refreshUrl. - */ - public com.google.protobuf.ByteString - getRefreshUrlBytes() { - java.lang.Object ref = refreshUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - refreshUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
    -     * The URL to be used for obtaining refresh tokens.
    -     * 
    - * - * string refresh_url = 2; - * @param value The refreshUrl to set. - * @return This builder for chaining. - */ - public Builder setRefreshUrl( - java.lang.String value) { - if (value == null) { throw new NullPointerException(); } - refreshUrl_ = value; - bitField0_ |= 0x00000002; - onChanged(); - return this; - } - /** - *
    -     * The URL to be used for obtaining refresh tokens.
    -     * 
    - * - * string refresh_url = 2; - * @return This builder for chaining. - */ - public Builder clearRefreshUrl() { - refreshUrl_ = getDefaultInstance().getRefreshUrl(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - *
    -     * The URL to be used for obtaining refresh tokens.
    -     * 
    - * - * string refresh_url = 2; - * @param value The bytes for refreshUrl to set. - * @return This builder for chaining. - */ - public Builder setRefreshUrlBytes( - com.google.protobuf.ByteString value) { - if (value == null) { throw new NullPointerException(); } - checkByteStringIsUtf8(value); - refreshUrl_ = value; - bitField0_ |= 0x00000002; - onChanged(); - return this; - } - - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> scopes_; - private com.google.protobuf.MapField - internalGetScopes() { - if (scopes_ == null) { - return com.google.protobuf.MapField.emptyMapField( - ScopesDefaultEntryHolder.defaultEntry); - } - return scopes_; - } - private com.google.protobuf.MapField - internalGetMutableScopes() { - if (scopes_ == null) { - scopes_ = com.google.protobuf.MapField.newMapField( - ScopesDefaultEntryHolder.defaultEntry); - } - if (!scopes_.isMutable()) { - scopes_ = scopes_.copy(); - } - bitField0_ |= 0x00000004; - onChanged(); - return scopes_; - } - public int getScopesCount() { - return internalGetScopes().getMap().size(); - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public boolean containsScopes( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - return internalGetScopes().getMap().containsKey(key); - } - /** - * Use {@link #getScopesMap()} instead. - */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getScopes() { - return getScopesMap(); - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public java.util.Map getScopesMap() { - return internalGetScopes().getMap(); - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public /* nullable */ -java.lang.String getScopesOrDefault( - java.lang.String key, - /* nullable */ -java.lang.String defaultValue) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetScopes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - @java.lang.Override - public java.lang.String getScopesOrThrow( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetScopes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - public Builder clearScopes() { - bitField0_ = (bitField0_ & ~0x00000004); - internalGetMutableScopes().getMutableMap() - .clear(); - return this; - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - public Builder removeScopes( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - internalGetMutableScopes().getMutableMap() - .remove(key); - return this; - } - /** - * Use alternate mutation accessors instead. - */ - @java.lang.Deprecated - public java.util.Map - getMutableScopes() { - bitField0_ |= 0x00000004; - return internalGetMutableScopes().getMutableMap(); - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - public Builder putScopes( - java.lang.String key, - java.lang.String value) { - if (key == null) { throw new NullPointerException("map key"); } - if (value == null) { throw new NullPointerException("map value"); } - internalGetMutableScopes().getMutableMap() - .put(key, value); - bitField0_ |= 0x00000004; - return this; - } - /** - *
    -     * The available scopes for the OAuth2 security scheme.
    -     * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - public Builder putAllScopes( - java.util.Map values) { - internalGetMutableScopes().getMutableMap() - .putAll(values); - bitField0_ |= 0x00000004; - return this; - } - - // @@protoc_insertion_point(builder_scope:a2a.v1.ImplicitOAuthFlow) - } - - // @@protoc_insertion_point(class_scope:a2a.v1.ImplicitOAuthFlow) - private static final io.a2a.grpc.ImplicitOAuthFlow DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new io.a2a.grpc.ImplicitOAuthFlow(); - } - - public static io.a2a.grpc.ImplicitOAuthFlow getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ImplicitOAuthFlow parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlow getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/spec-grpc/src/main/java/io/a2a/grpc/ImplicitOAuthFlowOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/ImplicitOAuthFlowOrBuilder.java deleted file mode 100644 index e59040641..000000000 --- a/spec-grpc/src/main/java/io/a2a/grpc/ImplicitOAuthFlowOrBuilder.java +++ /dev/null @@ -1,106 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// NO CHECKED-IN PROTOBUF GENCODE -// source: a2a.proto -// Protobuf Java Version: 4.33.1 - -package io.a2a.grpc; - -@com.google.protobuf.Generated -public interface ImplicitOAuthFlowOrBuilder extends - // @@protoc_insertion_point(interface_extends:a2a.v1.ImplicitOAuthFlow) - com.google.protobuf.MessageOrBuilder { - - /** - *
    -   * The authorization URL to be used for this flow.
    -   * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return The authorizationUrl. - */ - java.lang.String getAuthorizationUrl(); - /** - *
    -   * The authorization URL to be used for this flow.
    -   * 
    - * - * string authorization_url = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return The bytes for authorizationUrl. - */ - com.google.protobuf.ByteString - getAuthorizationUrlBytes(); - - /** - *
    -   * The URL to be used for obtaining refresh tokens.
    -   * 
    - * - * string refresh_url = 2; - * @return The refreshUrl. - */ - java.lang.String getRefreshUrl(); - /** - *
    -   * The URL to be used for obtaining refresh tokens.
    -   * 
    - * - * string refresh_url = 2; - * @return The bytes for refreshUrl. - */ - com.google.protobuf.ByteString - getRefreshUrlBytes(); - - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - int getScopesCount(); - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - boolean containsScopes( - java.lang.String key); - /** - * Use {@link #getScopesMap()} instead. - */ - @java.lang.Deprecated - java.util.Map - getScopes(); - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - java.util.Map - getScopesMap(); - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - /* nullable */ -java.lang.String getScopesOrDefault( - java.lang.String key, - /* nullable */ -java.lang.String defaultValue); - /** - *
    -   * The available scopes for the OAuth2 security scheme.
    -   * 
    - * - * map<string, string> scopes = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - java.lang.String getScopesOrThrow( - java.lang.String key); -} diff --git a/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequest.java b/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequest.java index 93d5a8bc9..c2645afcc 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequest.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequest.java @@ -276,20 +276,45 @@ public int getHistoryLength() { return historyLength_; } - public static final int LAST_UPDATED_AFTER_FIELD_NUMBER = 6; - private long lastUpdatedAfter_ = 0L; + public static final int STATUS_TIMESTAMP_AFTER_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp statusTimestampAfter_; /** *
    -   * Filter tasks updated after this timestamp (milliseconds since epoch).
    -   * Only tasks with a last updated time greater than or equal to this value will be returned.
    +   * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +   * Only tasks with a status timestamp time greater than or equal to this value will be returned.
        * 
    * - * int64 last_updated_after = 6; - * @return The lastUpdatedAfter. + * .google.protobuf.Timestamp status_timestamp_after = 6; + * @return Whether the statusTimestampAfter field is set. */ @java.lang.Override - public long getLastUpdatedAfter() { - return lastUpdatedAfter_; + public boolean hasStatusTimestampAfter() { + return ((bitField0_ & 0x00000004) != 0); + } + /** + *
    +   * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +   * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +   * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + * @return The statusTimestampAfter. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getStatusTimestampAfter() { + return statusTimestampAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : statusTimestampAfter_; + } + /** + *
    +   * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +   * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +   * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getStatusTimestampAfterOrBuilder() { + return statusTimestampAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : statusTimestampAfter_; } public static final int INCLUDE_ARTIFACTS_FIELD_NUMBER = 7; @@ -305,7 +330,7 @@ public long getLastUpdatedAfter() { */ @java.lang.Override public boolean hasIncludeArtifacts() { - return ((bitField0_ & 0x00000004) != 0); + return ((bitField0_ & 0x00000008) != 0); } /** *
    @@ -350,10 +375,10 @@ public void writeTo(com.google.protobuf.CodedOutputStream output)
         if (((bitField0_ & 0x00000002) != 0)) {
           output.writeInt32(5, historyLength_);
         }
    -    if (lastUpdatedAfter_ != 0L) {
    -      output.writeInt64(6, lastUpdatedAfter_);
    -    }
         if (((bitField0_ & 0x00000004) != 0)) {
    +      output.writeMessage(6, getStatusTimestampAfter());
    +    }
    +    if (((bitField0_ & 0x00000008) != 0)) {
           output.writeBool(7, includeArtifacts_);
         }
         if (!com.google.protobuf.GeneratedMessage.isStringEmpty(tenant_)) {
    @@ -386,11 +411,11 @@ public int getSerializedSize() {
           size += com.google.protobuf.CodedOutputStream
             .computeInt32Size(5, historyLength_);
         }
    -    if (lastUpdatedAfter_ != 0L) {
    +    if (((bitField0_ & 0x00000004) != 0)) {
           size += com.google.protobuf.CodedOutputStream
    -        .computeInt64Size(6, lastUpdatedAfter_);
    +        .computeMessageSize(6, getStatusTimestampAfter());
         }
    -    if (((bitField0_ & 0x00000004) != 0)) {
    +    if (((bitField0_ & 0x00000008) != 0)) {
           size += com.google.protobuf.CodedOutputStream
             .computeBoolSize(7, includeArtifacts_);
         }
    @@ -429,8 +454,11 @@ public boolean equals(final java.lang.Object obj) {
           if (getHistoryLength()
               != other.getHistoryLength()) return false;
         }
    -    if (getLastUpdatedAfter()
    -        != other.getLastUpdatedAfter()) return false;
    +    if (hasStatusTimestampAfter() != other.hasStatusTimestampAfter()) return false;
    +    if (hasStatusTimestampAfter()) {
    +      if (!getStatusTimestampAfter()
    +          .equals(other.getStatusTimestampAfter())) return false;
    +    }
         if (hasIncludeArtifacts() != other.hasIncludeArtifacts()) return false;
         if (hasIncludeArtifacts()) {
           if (getIncludeArtifacts()
    @@ -463,9 +491,10 @@ public int hashCode() {
           hash = (37 * hash) + HISTORY_LENGTH_FIELD_NUMBER;
           hash = (53 * hash) + getHistoryLength();
         }
    -    hash = (37 * hash) + LAST_UPDATED_AFTER_FIELD_NUMBER;
    -    hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
    -        getLastUpdatedAfter());
    +    if (hasStatusTimestampAfter()) {
    +      hash = (37 * hash) + STATUS_TIMESTAMP_AFTER_FIELD_NUMBER;
    +      hash = (53 * hash) + getStatusTimestampAfter().hashCode();
    +    }
         if (hasIncludeArtifacts()) {
           hash = (37 * hash) + INCLUDE_ARTIFACTS_FIELD_NUMBER;
           hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
    @@ -595,13 +624,19 @@ public static final class Builder extends
     
         // Construct using io.a2a.grpc.ListTasksRequest.newBuilder()
         private Builder() {
    -
    +      maybeForceBuilderInitialization();
         }
     
         private Builder(
             com.google.protobuf.GeneratedMessage.BuilderParent parent) {
           super(parent);
    -
    +      maybeForceBuilderInitialization();
    +    }
    +    private void maybeForceBuilderInitialization() {
    +      if (com.google.protobuf.GeneratedMessage
    +              .alwaysUseFieldBuilders) {
    +        internalGetStatusTimestampAfterFieldBuilder();
    +      }
         }
         @java.lang.Override
         public Builder clear() {
    @@ -613,7 +648,11 @@ public Builder clear() {
           pageSize_ = 0;
           pageToken_ = "";
           historyLength_ = 0;
    -      lastUpdatedAfter_ = 0L;
    +      statusTimestampAfter_ = null;
    +      if (statusTimestampAfterBuilder_ != null) {
    +        statusTimestampAfterBuilder_.dispose();
    +        statusTimestampAfterBuilder_ = null;
    +      }
           includeArtifacts_ = false;
           return this;
         }
    @@ -670,11 +709,14 @@ private void buildPartial0(io.a2a.grpc.ListTasksRequest result) {
             to_bitField0_ |= 0x00000002;
           }
           if (((from_bitField0_ & 0x00000040) != 0)) {
    -        result.lastUpdatedAfter_ = lastUpdatedAfter_;
    +        result.statusTimestampAfter_ = statusTimestampAfterBuilder_ == null
    +            ? statusTimestampAfter_
    +            : statusTimestampAfterBuilder_.build();
    +        to_bitField0_ |= 0x00000004;
           }
           if (((from_bitField0_ & 0x00000080) != 0)) {
             result.includeArtifacts_ = includeArtifacts_;
    -        to_bitField0_ |= 0x00000004;
    +        to_bitField0_ |= 0x00000008;
           }
           result.bitField0_ |= to_bitField0_;
         }
    @@ -715,8 +757,8 @@ public Builder mergeFrom(io.a2a.grpc.ListTasksRequest other) {
           if (other.hasHistoryLength()) {
             setHistoryLength(other.getHistoryLength());
           }
    -      if (other.getLastUpdatedAfter() != 0L) {
    -        setLastUpdatedAfter(other.getLastUpdatedAfter());
    +      if (other.hasStatusTimestampAfter()) {
    +        mergeStatusTimestampAfter(other.getStatusTimestampAfter());
           }
           if (other.hasIncludeArtifacts()) {
             setIncludeArtifacts(other.getIncludeArtifacts());
    @@ -772,11 +814,13 @@ public Builder mergeFrom(
                   bitField0_ |= 0x00000020;
                   break;
                 } // case 40
    -            case 48: {
    -              lastUpdatedAfter_ = input.readInt64();
    +            case 50: {
    +              input.readMessage(
    +                  internalGetStatusTimestampAfterFieldBuilder().getBuilder(),
    +                  extensionRegistry);
                   bitField0_ |= 0x00000040;
                   break;
    -            } // case 48
    +            } // case 50
                 case 56: {
                   includeArtifacts_ = input.readBool();
                   bitField0_ |= 0x00000080;
    @@ -1267,52 +1311,171 @@ public Builder clearHistoryLength() {
           return this;
         }
     
    -    private long lastUpdatedAfter_ ;
    +    private com.google.protobuf.Timestamp statusTimestampAfter_;
    +    private com.google.protobuf.SingleFieldBuilder<
    +        com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> statusTimestampAfterBuilder_;
         /**
          * 
    -     * Filter tasks updated after this timestamp (milliseconds since epoch).
    -     * Only tasks with a last updated time greater than or equal to this value will be returned.
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
          * 
    * - * int64 last_updated_after = 6; - * @return The lastUpdatedAfter. + * .google.protobuf.Timestamp status_timestamp_after = 6; + * @return Whether the statusTimestampAfter field is set. */ - @java.lang.Override - public long getLastUpdatedAfter() { - return lastUpdatedAfter_; + public boolean hasStatusTimestampAfter() { + return ((bitField0_ & 0x00000040) != 0); } /** *
    -     * Filter tasks updated after this timestamp (milliseconds since epoch).
    -     * Only tasks with a last updated time greater than or equal to this value will be returned.
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
          * 
    * - * int64 last_updated_after = 6; - * @param value The lastUpdatedAfter to set. - * @return This builder for chaining. + * .google.protobuf.Timestamp status_timestamp_after = 6; + * @return The statusTimestampAfter. */ - public Builder setLastUpdatedAfter(long value) { - - lastUpdatedAfter_ = value; + public com.google.protobuf.Timestamp getStatusTimestampAfter() { + if (statusTimestampAfterBuilder_ == null) { + return statusTimestampAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : statusTimestampAfter_; + } else { + return statusTimestampAfterBuilder_.getMessage(); + } + } + /** + *
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +     * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + public Builder setStatusTimestampAfter(com.google.protobuf.Timestamp value) { + if (statusTimestampAfterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + statusTimestampAfter_ = value; + } else { + statusTimestampAfterBuilder_.setMessage(value); + } bitField0_ |= 0x00000040; onChanged(); return this; } /** *
    -     * Filter tasks updated after this timestamp (milliseconds since epoch).
    -     * Only tasks with a last updated time greater than or equal to this value will be returned.
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
          * 
    * - * int64 last_updated_after = 6; - * @return This builder for chaining. + * .google.protobuf.Timestamp status_timestamp_after = 6; */ - public Builder clearLastUpdatedAfter() { + public Builder setStatusTimestampAfter( + com.google.protobuf.Timestamp.Builder builderForValue) { + if (statusTimestampAfterBuilder_ == null) { + statusTimestampAfter_ = builderForValue.build(); + } else { + statusTimestampAfterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + /** + *
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +     * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + public Builder mergeStatusTimestampAfter(com.google.protobuf.Timestamp value) { + if (statusTimestampAfterBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) && + statusTimestampAfter_ != null && + statusTimestampAfter_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getStatusTimestampAfterBuilder().mergeFrom(value); + } else { + statusTimestampAfter_ = value; + } + } else { + statusTimestampAfterBuilder_.mergeFrom(value); + } + if (statusTimestampAfter_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + /** + *
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +     * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + public Builder clearStatusTimestampAfter() { bitField0_ = (bitField0_ & ~0x00000040); - lastUpdatedAfter_ = 0L; + statusTimestampAfter_ = null; + if (statusTimestampAfterBuilder_ != null) { + statusTimestampAfterBuilder_.dispose(); + statusTimestampAfterBuilder_ = null; + } onChanged(); return this; } + /** + *
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +     * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + public com.google.protobuf.Timestamp.Builder getStatusTimestampAfterBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetStatusTimestampAfterFieldBuilder().getBuilder(); + } + /** + *
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +     * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + public com.google.protobuf.TimestampOrBuilder getStatusTimestampAfterOrBuilder() { + if (statusTimestampAfterBuilder_ != null) { + return statusTimestampAfterBuilder_.getMessageOrBuilder(); + } else { + return statusTimestampAfter_ == null ? + com.google.protobuf.Timestamp.getDefaultInstance() : statusTimestampAfter_; + } + } + /** + *
    +     * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +     * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +     * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + internalGetStatusTimestampAfterFieldBuilder() { + if (statusTimestampAfterBuilder_ == null) { + statusTimestampAfterBuilder_ = new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( + getStatusTimestampAfter(), + getParentForChildren(), + isClean()); + statusTimestampAfter_ = null; + } + return statusTimestampAfterBuilder_; + } private boolean includeArtifacts_ ; /** diff --git a/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequestOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequestOrBuilder.java index 6b832c0d1..410485d50 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequestOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/ListTasksRequestOrBuilder.java @@ -131,14 +131,33 @@ public interface ListTasksRequestOrBuilder extends /** *
    -   * Filter tasks updated after this timestamp (milliseconds since epoch).
    -   * Only tasks with a last updated time greater than or equal to this value will be returned.
    +   * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +   * Only tasks with a status timestamp time greater than or equal to this value will be returned.
        * 
    * - * int64 last_updated_after = 6; - * @return The lastUpdatedAfter. + * .google.protobuf.Timestamp status_timestamp_after = 6; + * @return Whether the statusTimestampAfter field is set. */ - long getLastUpdatedAfter(); + boolean hasStatusTimestampAfter(); + /** + *
    +   * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +   * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +   * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + * @return The statusTimestampAfter. + */ + com.google.protobuf.Timestamp getStatusTimestampAfter(); + /** + *
    +   * Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z").
    +   * Only tasks with a status timestamp time greater than or equal to this value will be returned.
    +   * 
    + * + * .google.protobuf.Timestamp status_timestamp_after = 6; + */ + com.google.protobuf.TimestampOrBuilder getStatusTimestampAfterOrBuilder(); /** *
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/Message.java b/spec-grpc/src/main/java/io/a2a/grpc/Message.java
    index 8ff6a60f6..e8f296411 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/Message.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/Message.java
    @@ -8,13 +8,12 @@
     /**
      * 
      * --8<-- [start:Message]
    - * Message is one unit of communication between client and server. It is
    - * associated with a context and optionally a task. Since the server is
    - * responsible for the context definition, it must always provide a context_id
    - * in its messages. The client can optionally provide the context_id if it
    - * knows the context to associate the message to. Similarly for task_id,
    - * except the server decides if a task is created and whether to include the
    - * task_id.
    + * Message is one unit of communication between client and server. It can be
    + * associated with a context and/or a task. For server messages, context_id must
    + * be provided, and task_id only if a task was created. For client messages, both
    + * fields are optional, with the caveat that if both are provided, they have to
    + * match (the context_id has to be the one that is set on the task). If only
    + * task_id is provided, the server will infer context_id from it.
      * 
    * * Protobuf type {@code a2a.v1.Message} @@ -702,13 +701,12 @@ protected Builder newBuilderForType( /** *
        * --8<-- [start:Message]
    -   * Message is one unit of communication between client and server. It is
    -   * associated with a context and optionally a task. Since the server is
    -   * responsible for the context definition, it must always provide a context_id
    -   * in its messages. The client can optionally provide the context_id if it
    -   * knows the context to associate the message to. Similarly for task_id,
    -   * except the server decides if a task is created and whether to include the
    -   * task_id.
    +   * Message is one unit of communication between client and server. It can be
    +   * associated with a context and/or a task. For server messages, context_id must
    +   * be provided, and task_id only if a task was created. For client messages, both
    +   * fields are optional, with the caveat that if both are provided, they have to
    +   * match (the context_id has to be the one that is set on the task). If only
    +   * task_id is provided, the server will infer context_id from it.
        * 
    * * Protobuf type {@code a2a.v1.Message} diff --git a/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlows.java b/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlows.java index f2da009e6..e4fd7c957 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlows.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlows.java @@ -56,8 +56,7 @@ public enum FlowCase com.google.protobuf.AbstractMessage.InternalOneOfEnum { AUTHORIZATION_CODE(1), CLIENT_CREDENTIALS(2), - IMPLICIT(3), - PASSWORD(4), + DEVICE_CODE(5), FLOW_NOT_SET(0); private final int value; private FlowCase(int value) { @@ -77,8 +76,7 @@ public static FlowCase forNumber(int value) { switch (value) { case 1: return AUTHORIZATION_CODE; case 2: return CLIENT_CREDENTIALS; - case 3: return IMPLICIT; - case 4: return PASSWORD; + case 5: return DEVICE_CODE; case 0: return FLOW_NOT_SET; default: return null; } @@ -180,90 +178,47 @@ public io.a2a.grpc.ClientCredentialsOAuthFlowOrBuilder getClientCredentialsOrBui return io.a2a.grpc.ClientCredentialsOAuthFlow.getDefaultInstance(); } - public static final int IMPLICIT_FIELD_NUMBER = 3; + public static final int DEVICE_CODE_FIELD_NUMBER = 5; /** *
    -   * Configuration for the OAuth Implicit flow.
    +   * Configuration for the OAuth Device Code flow.
        * 
    * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - * @return Whether the implicit field is set. + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; + * @return Whether the deviceCode field is set. */ @java.lang.Override - public boolean hasImplicit() { - return flowCase_ == 3; + public boolean hasDeviceCode() { + return flowCase_ == 5; } /** *
    -   * Configuration for the OAuth Implicit flow.
    +   * Configuration for the OAuth Device Code flow.
        * 
    * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - * @return The implicit. + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; + * @return The deviceCode. */ @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlow getImplicit() { - if (flowCase_ == 3) { - return (io.a2a.grpc.ImplicitOAuthFlow) flow_; + public io.a2a.grpc.DeviceCodeOAuthFlow getDeviceCode() { + if (flowCase_ == 5) { + return (io.a2a.grpc.DeviceCodeOAuthFlow) flow_; } - return io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); + return io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } /** *
    -   * Configuration for the OAuth Implicit flow.
    +   * Configuration for the OAuth Device Code flow.
        * 
    * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlowOrBuilder getImplicitOrBuilder() { - if (flowCase_ == 3) { - return (io.a2a.grpc.ImplicitOAuthFlow) flow_; + public io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder getDeviceCodeOrBuilder() { + if (flowCase_ == 5) { + return (io.a2a.grpc.DeviceCodeOAuthFlow) flow_; } - return io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); - } - - public static final int PASSWORD_FIELD_NUMBER = 4; - /** - *
    -   * Configuration for the OAuth Resource Owner Password flow.
    -   * 
    - * - * .a2a.v1.PasswordOAuthFlow password = 4; - * @return Whether the password field is set. - */ - @java.lang.Override - public boolean hasPassword() { - return flowCase_ == 4; - } - /** - *
    -   * Configuration for the OAuth Resource Owner Password flow.
    -   * 
    - * - * .a2a.v1.PasswordOAuthFlow password = 4; - * @return The password. - */ - @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlow getPassword() { - if (flowCase_ == 4) { - return (io.a2a.grpc.PasswordOAuthFlow) flow_; - } - return io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); - } - /** - *
    -   * Configuration for the OAuth Resource Owner Password flow.
    -   * 
    - * - * .a2a.v1.PasswordOAuthFlow password = 4; - */ - @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlowOrBuilder getPasswordOrBuilder() { - if (flowCase_ == 4) { - return (io.a2a.grpc.PasswordOAuthFlow) flow_; - } - return io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); + return io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } private byte memoizedIsInitialized = -1; @@ -286,11 +241,8 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) if (flowCase_ == 2) { output.writeMessage(2, (io.a2a.grpc.ClientCredentialsOAuthFlow) flow_); } - if (flowCase_ == 3) { - output.writeMessage(3, (io.a2a.grpc.ImplicitOAuthFlow) flow_); - } - if (flowCase_ == 4) { - output.writeMessage(4, (io.a2a.grpc.PasswordOAuthFlow) flow_); + if (flowCase_ == 5) { + output.writeMessage(5, (io.a2a.grpc.DeviceCodeOAuthFlow) flow_); } getUnknownFields().writeTo(output); } @@ -309,13 +261,9 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, (io.a2a.grpc.ClientCredentialsOAuthFlow) flow_); } - if (flowCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (io.a2a.grpc.ImplicitOAuthFlow) flow_); - } - if (flowCase_ == 4) { + if (flowCase_ == 5) { size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (io.a2a.grpc.PasswordOAuthFlow) flow_); + .computeMessageSize(5, (io.a2a.grpc.DeviceCodeOAuthFlow) flow_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -342,13 +290,9 @@ public boolean equals(final java.lang.Object obj) { if (!getClientCredentials() .equals(other.getClientCredentials())) return false; break; - case 3: - if (!getImplicit() - .equals(other.getImplicit())) return false; - break; - case 4: - if (!getPassword() - .equals(other.getPassword())) return false; + case 5: + if (!getDeviceCode() + .equals(other.getDeviceCode())) return false; break; case 0: default: @@ -373,13 +317,9 @@ public int hashCode() { hash = (37 * hash) + CLIENT_CREDENTIALS_FIELD_NUMBER; hash = (53 * hash) + getClientCredentials().hashCode(); break; - case 3: - hash = (37 * hash) + IMPLICIT_FIELD_NUMBER; - hash = (53 * hash) + getImplicit().hashCode(); - break; - case 4: - hash = (37 * hash) + PASSWORD_FIELD_NUMBER; - hash = (53 * hash) + getPassword().hashCode(); + case 5: + hash = (37 * hash) + DEVICE_CODE_FIELD_NUMBER; + hash = (53 * hash) + getDeviceCode().hashCode(); break; case 0: default: @@ -526,11 +466,8 @@ public Builder clear() { if (clientCredentialsBuilder_ != null) { clientCredentialsBuilder_.clear(); } - if (implicitBuilder_ != null) { - implicitBuilder_.clear(); - } - if (passwordBuilder_ != null) { - passwordBuilder_.clear(); + if (deviceCodeBuilder_ != null) { + deviceCodeBuilder_.clear(); } flowCase_ = 0; flow_ = null; @@ -581,13 +518,9 @@ private void buildPartialOneofs(io.a2a.grpc.OAuthFlows result) { clientCredentialsBuilder_ != null) { result.flow_ = clientCredentialsBuilder_.build(); } - if (flowCase_ == 3 && - implicitBuilder_ != null) { - result.flow_ = implicitBuilder_.build(); - } - if (flowCase_ == 4 && - passwordBuilder_ != null) { - result.flow_ = passwordBuilder_.build(); + if (flowCase_ == 5 && + deviceCodeBuilder_ != null) { + result.flow_ = deviceCodeBuilder_.build(); } } @@ -612,12 +545,8 @@ public Builder mergeFrom(io.a2a.grpc.OAuthFlows other) { mergeClientCredentials(other.getClientCredentials()); break; } - case IMPLICIT: { - mergeImplicit(other.getImplicit()); - break; - } - case PASSWORD: { - mergePassword(other.getPassword()); + case DEVICE_CODE: { + mergeDeviceCode(other.getDeviceCode()); break; } case FLOW_NOT_SET: { @@ -664,20 +593,13 @@ public Builder mergeFrom( flowCase_ = 2; break; } // case 18 - case 26: { - input.readMessage( - internalGetImplicitFieldBuilder().getBuilder(), - extensionRegistry); - flowCase_ = 3; - break; - } // case 26 - case 34: { + case 42: { input.readMessage( - internalGetPasswordFieldBuilder().getBuilder(), + internalGetDeviceCodeFieldBuilder().getBuilder(), extensionRegistry); - flowCase_ = 4; + flowCase_ = 5; break; - } // case 34 + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag @@ -1067,359 +989,181 @@ public io.a2a.grpc.ClientCredentialsOAuthFlowOrBuilder getClientCredentialsOrBui } private com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.ImplicitOAuthFlow, io.a2a.grpc.ImplicitOAuthFlow.Builder, io.a2a.grpc.ImplicitOAuthFlowOrBuilder> implicitBuilder_; - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - * @return Whether the implicit field is set. - */ - @java.lang.Override - public boolean hasImplicit() { - return flowCase_ == 3; - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - * @return The implicit. - */ - @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlow getImplicit() { - if (implicitBuilder_ == null) { - if (flowCase_ == 3) { - return (io.a2a.grpc.ImplicitOAuthFlow) flow_; - } - return io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); - } else { - if (flowCase_ == 3) { - return implicitBuilder_.getMessage(); - } - return io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); - } - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - public Builder setImplicit(io.a2a.grpc.ImplicitOAuthFlow value) { - if (implicitBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - flow_ = value; - onChanged(); - } else { - implicitBuilder_.setMessage(value); - } - flowCase_ = 3; - return this; - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - public Builder setImplicit( - io.a2a.grpc.ImplicitOAuthFlow.Builder builderForValue) { - if (implicitBuilder_ == null) { - flow_ = builderForValue.build(); - onChanged(); - } else { - implicitBuilder_.setMessage(builderForValue.build()); - } - flowCase_ = 3; - return this; - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - public Builder mergeImplicit(io.a2a.grpc.ImplicitOAuthFlow value) { - if (implicitBuilder_ == null) { - if (flowCase_ == 3 && - flow_ != io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance()) { - flow_ = io.a2a.grpc.ImplicitOAuthFlow.newBuilder((io.a2a.grpc.ImplicitOAuthFlow) flow_) - .mergeFrom(value).buildPartial(); - } else { - flow_ = value; - } - onChanged(); - } else { - if (flowCase_ == 3) { - implicitBuilder_.mergeFrom(value); - } else { - implicitBuilder_.setMessage(value); - } - } - flowCase_ = 3; - return this; - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - public Builder clearImplicit() { - if (implicitBuilder_ == null) { - if (flowCase_ == 3) { - flowCase_ = 0; - flow_ = null; - onChanged(); - } - } else { - if (flowCase_ == 3) { - flowCase_ = 0; - flow_ = null; - } - implicitBuilder_.clear(); - } - return this; - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - public io.a2a.grpc.ImplicitOAuthFlow.Builder getImplicitBuilder() { - return internalGetImplicitFieldBuilder().getBuilder(); - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - @java.lang.Override - public io.a2a.grpc.ImplicitOAuthFlowOrBuilder getImplicitOrBuilder() { - if ((flowCase_ == 3) && (implicitBuilder_ != null)) { - return implicitBuilder_.getMessageOrBuilder(); - } else { - if (flowCase_ == 3) { - return (io.a2a.grpc.ImplicitOAuthFlow) flow_; - } - return io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); - } - } - /** - *
    -     * Configuration for the OAuth Implicit flow.
    -     * 
    - * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - */ - private com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.ImplicitOAuthFlow, io.a2a.grpc.ImplicitOAuthFlow.Builder, io.a2a.grpc.ImplicitOAuthFlowOrBuilder> - internalGetImplicitFieldBuilder() { - if (implicitBuilder_ == null) { - if (!(flowCase_ == 3)) { - flow_ = io.a2a.grpc.ImplicitOAuthFlow.getDefaultInstance(); - } - implicitBuilder_ = new com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.ImplicitOAuthFlow, io.a2a.grpc.ImplicitOAuthFlow.Builder, io.a2a.grpc.ImplicitOAuthFlowOrBuilder>( - (io.a2a.grpc.ImplicitOAuthFlow) flow_, - getParentForChildren(), - isClean()); - flow_ = null; - } - flowCase_ = 3; - onChanged(); - return implicitBuilder_; - } - - private com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.PasswordOAuthFlow, io.a2a.grpc.PasswordOAuthFlow.Builder, io.a2a.grpc.PasswordOAuthFlowOrBuilder> passwordBuilder_; + io.a2a.grpc.DeviceCodeOAuthFlow, io.a2a.grpc.DeviceCodeOAuthFlow.Builder, io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder> deviceCodeBuilder_; /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; - * @return Whether the password field is set. + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; + * @return Whether the deviceCode field is set. */ @java.lang.Override - public boolean hasPassword() { - return flowCase_ == 4; + public boolean hasDeviceCode() { + return flowCase_ == 5; } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; - * @return The password. + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; + * @return The deviceCode. */ @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlow getPassword() { - if (passwordBuilder_ == null) { - if (flowCase_ == 4) { - return (io.a2a.grpc.PasswordOAuthFlow) flow_; + public io.a2a.grpc.DeviceCodeOAuthFlow getDeviceCode() { + if (deviceCodeBuilder_ == null) { + if (flowCase_ == 5) { + return (io.a2a.grpc.DeviceCodeOAuthFlow) flow_; } - return io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); + return io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } else { - if (flowCase_ == 4) { - return passwordBuilder_.getMessage(); + if (flowCase_ == 5) { + return deviceCodeBuilder_.getMessage(); } - return io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); + return io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ - public Builder setPassword(io.a2a.grpc.PasswordOAuthFlow value) { - if (passwordBuilder_ == null) { + public Builder setDeviceCode(io.a2a.grpc.DeviceCodeOAuthFlow value) { + if (deviceCodeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } flow_ = value; onChanged(); } else { - passwordBuilder_.setMessage(value); + deviceCodeBuilder_.setMessage(value); } - flowCase_ = 4; + flowCase_ = 5; return this; } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ - public Builder setPassword( - io.a2a.grpc.PasswordOAuthFlow.Builder builderForValue) { - if (passwordBuilder_ == null) { + public Builder setDeviceCode( + io.a2a.grpc.DeviceCodeOAuthFlow.Builder builderForValue) { + if (deviceCodeBuilder_ == null) { flow_ = builderForValue.build(); onChanged(); } else { - passwordBuilder_.setMessage(builderForValue.build()); + deviceCodeBuilder_.setMessage(builderForValue.build()); } - flowCase_ = 4; + flowCase_ = 5; return this; } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ - public Builder mergePassword(io.a2a.grpc.PasswordOAuthFlow value) { - if (passwordBuilder_ == null) { - if (flowCase_ == 4 && - flow_ != io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance()) { - flow_ = io.a2a.grpc.PasswordOAuthFlow.newBuilder((io.a2a.grpc.PasswordOAuthFlow) flow_) + public Builder mergeDeviceCode(io.a2a.grpc.DeviceCodeOAuthFlow value) { + if (deviceCodeBuilder_ == null) { + if (flowCase_ == 5 && + flow_ != io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance()) { + flow_ = io.a2a.grpc.DeviceCodeOAuthFlow.newBuilder((io.a2a.grpc.DeviceCodeOAuthFlow) flow_) .mergeFrom(value).buildPartial(); } else { flow_ = value; } onChanged(); } else { - if (flowCase_ == 4) { - passwordBuilder_.mergeFrom(value); + if (flowCase_ == 5) { + deviceCodeBuilder_.mergeFrom(value); } else { - passwordBuilder_.setMessage(value); + deviceCodeBuilder_.setMessage(value); } } - flowCase_ = 4; + flowCase_ = 5; return this; } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ - public Builder clearPassword() { - if (passwordBuilder_ == null) { - if (flowCase_ == 4) { + public Builder clearDeviceCode() { + if (deviceCodeBuilder_ == null) { + if (flowCase_ == 5) { flowCase_ = 0; flow_ = null; onChanged(); } } else { - if (flowCase_ == 4) { + if (flowCase_ == 5) { flowCase_ = 0; flow_ = null; } - passwordBuilder_.clear(); + deviceCodeBuilder_.clear(); } return this; } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ - public io.a2a.grpc.PasswordOAuthFlow.Builder getPasswordBuilder() { - return internalGetPasswordFieldBuilder().getBuilder(); + public io.a2a.grpc.DeviceCodeOAuthFlow.Builder getDeviceCodeBuilder() { + return internalGetDeviceCodeFieldBuilder().getBuilder(); } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ @java.lang.Override - public io.a2a.grpc.PasswordOAuthFlowOrBuilder getPasswordOrBuilder() { - if ((flowCase_ == 4) && (passwordBuilder_ != null)) { - return passwordBuilder_.getMessageOrBuilder(); + public io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder getDeviceCodeOrBuilder() { + if ((flowCase_ == 5) && (deviceCodeBuilder_ != null)) { + return deviceCodeBuilder_.getMessageOrBuilder(); } else { - if (flowCase_ == 4) { - return (io.a2a.grpc.PasswordOAuthFlow) flow_; + if (flowCase_ == 5) { + return (io.a2a.grpc.DeviceCodeOAuthFlow) flow_; } - return io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); + return io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } } /** *
    -     * Configuration for the OAuth Resource Owner Password flow.
    +     * Configuration for the OAuth Device Code flow.
          * 
    * - * .a2a.v1.PasswordOAuthFlow password = 4; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ private com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.PasswordOAuthFlow, io.a2a.grpc.PasswordOAuthFlow.Builder, io.a2a.grpc.PasswordOAuthFlowOrBuilder> - internalGetPasswordFieldBuilder() { - if (passwordBuilder_ == null) { - if (!(flowCase_ == 4)) { - flow_ = io.a2a.grpc.PasswordOAuthFlow.getDefaultInstance(); + io.a2a.grpc.DeviceCodeOAuthFlow, io.a2a.grpc.DeviceCodeOAuthFlow.Builder, io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder> + internalGetDeviceCodeFieldBuilder() { + if (deviceCodeBuilder_ == null) { + if (!(flowCase_ == 5)) { + flow_ = io.a2a.grpc.DeviceCodeOAuthFlow.getDefaultInstance(); } - passwordBuilder_ = new com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.PasswordOAuthFlow, io.a2a.grpc.PasswordOAuthFlow.Builder, io.a2a.grpc.PasswordOAuthFlowOrBuilder>( - (io.a2a.grpc.PasswordOAuthFlow) flow_, + deviceCodeBuilder_ = new com.google.protobuf.SingleFieldBuilder< + io.a2a.grpc.DeviceCodeOAuthFlow, io.a2a.grpc.DeviceCodeOAuthFlow.Builder, io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder>( + (io.a2a.grpc.DeviceCodeOAuthFlow) flow_, getParentForChildren(), isClean()); flow_ = null; } - flowCase_ = 4; + flowCase_ = 5; onChanged(); - return passwordBuilder_; + return deviceCodeBuilder_; } // @@protoc_insertion_point(builder_scope:a2a.v1.OAuthFlows) diff --git a/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlowsOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlowsOrBuilder.java index 1bdc0f5e0..cb84fa83e 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlowsOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/OAuthFlowsOrBuilder.java @@ -66,57 +66,30 @@ public interface OAuthFlowsOrBuilder extends /** *
    -   * Configuration for the OAuth Implicit flow.
    +   * Configuration for the OAuth Device Code flow.
        * 
    * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - * @return Whether the implicit field is set. + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; + * @return Whether the deviceCode field is set. */ - boolean hasImplicit(); + boolean hasDeviceCode(); /** *
    -   * Configuration for the OAuth Implicit flow.
    +   * Configuration for the OAuth Device Code flow.
        * 
    * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; - * @return The implicit. + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; + * @return The deviceCode. */ - io.a2a.grpc.ImplicitOAuthFlow getImplicit(); + io.a2a.grpc.DeviceCodeOAuthFlow getDeviceCode(); /** *
    -   * Configuration for the OAuth Implicit flow.
    +   * Configuration for the OAuth Device Code flow.
        * 
    * - * .a2a.v1.ImplicitOAuthFlow implicit = 3; + * .a2a.v1.DeviceCodeOAuthFlow device_code = 5; */ - io.a2a.grpc.ImplicitOAuthFlowOrBuilder getImplicitOrBuilder(); - - /** - *
    -   * Configuration for the OAuth Resource Owner Password flow.
    -   * 
    - * - * .a2a.v1.PasswordOAuthFlow password = 4; - * @return Whether the password field is set. - */ - boolean hasPassword(); - /** - *
    -   * Configuration for the OAuth Resource Owner Password flow.
    -   * 
    - * - * .a2a.v1.PasswordOAuthFlow password = 4; - * @return The password. - */ - io.a2a.grpc.PasswordOAuthFlow getPassword(); - /** - *
    -   * Configuration for the OAuth Resource Owner Password flow.
    -   * 
    - * - * .a2a.v1.PasswordOAuthFlow password = 4; - */ - io.a2a.grpc.PasswordOAuthFlowOrBuilder getPasswordOrBuilder(); + io.a2a.grpc.DeviceCodeOAuthFlowOrBuilder getDeviceCodeOrBuilder(); io.a2a.grpc.OAuthFlows.FlowCase getFlowCase(); } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfiguration.java b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfiguration.java index 457c55b1f..6bec1fb51 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfiguration.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfiguration.java @@ -146,7 +146,10 @@ public io.a2a.grpc.PushNotificationConfigOrBuilder getPushNotificationConfigOrBu private int historyLength_ = 0; /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve in
    +   * the response. An unset value means the client does not impose any limit. A
    +   * value of zero is a request to not include any messages. The server MUST NOT
    +   * return more messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 3; @@ -158,7 +161,10 @@ public boolean hasHistoryLength() { } /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve in
    +   * the response. An unset value means the client does not impose any limit. A
    +   * value of zero is a request to not include any messages. The server MUST NOT
    +   * return more messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 3; @@ -903,7 +909,10 @@ public io.a2a.grpc.PushNotificationConfigOrBuilder getPushNotificationConfigOrBu private int historyLength_ ; /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve in
    +     * the response. An unset value means the client does not impose any limit. A
    +     * value of zero is a request to not include any messages. The server MUST NOT
    +     * return more messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 3; @@ -915,7 +924,10 @@ public boolean hasHistoryLength() { } /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve in
    +     * the response. An unset value means the client does not impose any limit. A
    +     * value of zero is a request to not include any messages. The server MUST NOT
    +     * return more messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 3; @@ -927,7 +939,10 @@ public int getHistoryLength() { } /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve in
    +     * the response. An unset value means the client does not impose any limit. A
    +     * value of zero is a request to not include any messages. The server MUST NOT
    +     * return more messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 3; @@ -943,7 +958,10 @@ public Builder setHistoryLength(int value) { } /** *
    -     * The maximum number of messages to include in the history.
    +     * The maximum number of most recent messages from the task's history to retrieve in
    +     * the response. An unset value means the client does not impose any limit. A
    +     * value of zero is a request to not include any messages. The server MUST NOT
    +     * return more messages than the provided value, but MAY apply a lower limit.
          * 
    * * optional int32 history_length = 3; diff --git a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfigurationOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfigurationOrBuilder.java index cfbab940c..2fed6a6af 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfigurationOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageConfigurationOrBuilder.java @@ -80,7 +80,10 @@ public interface SendMessageConfigurationOrBuilder extends /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve in
    +   * the response. An unset value means the client does not impose any limit. A
    +   * value of zero is a request to not include any messages. The server MUST NOT
    +   * return more messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 3; @@ -89,7 +92,10 @@ public interface SendMessageConfigurationOrBuilder extends boolean hasHistoryLength(); /** *
    -   * The maximum number of messages to include in the history.
    +   * The maximum number of most recent messages from the task's history to retrieve in
    +   * the response. An unset value means the client does not impose any limit. A
    +   * value of zero is a request to not include any messages. The server MUST NOT
    +   * return more messages than the provided value, but MAY apply a lower limit.
        * 
    * * optional int32 history_length = 3; diff --git a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequest.java b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequest.java index 41ba38002..caaf9740e 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequest.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequest.java @@ -98,18 +98,18 @@ public java.lang.String getTenant() { } } - public static final int REQUEST_FIELD_NUMBER = 1; - private io.a2a.grpc.Message request_; + public static final int MESSAGE_FIELD_NUMBER = 1; + private io.a2a.grpc.Message message_; /** *
        * The message to send to the agent.
        * 
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; - * @return Whether the request field is set. + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return Whether the message field is set. */ @java.lang.Override - public boolean hasRequest() { + public boolean hasMessage() { return ((bitField0_ & 0x00000001) != 0); } /** @@ -117,23 +117,23 @@ public boolean hasRequest() { * The message to send to the agent. *
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; - * @return The request. + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The message. */ @java.lang.Override - public io.a2a.grpc.Message getRequest() { - return request_ == null ? io.a2a.grpc.Message.getDefaultInstance() : request_; + public io.a2a.grpc.Message getMessage() { + return message_ == null ? io.a2a.grpc.Message.getDefaultInstance() : message_; } /** *
        * The message to send to the agent.
        * 
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ @java.lang.Override - public io.a2a.grpc.MessageOrBuilder getRequestOrBuilder() { - return request_ == null ? io.a2a.grpc.Message.getDefaultInstance() : request_; + public io.a2a.grpc.MessageOrBuilder getMessageOrBuilder() { + return message_ == null ? io.a2a.grpc.Message.getDefaultInstance() : message_; } public static final int CONFIGURATION_FIELD_NUMBER = 2; @@ -227,7 +227,7 @@ public final boolean isInitialized() { public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (((bitField0_ & 0x00000001) != 0)) { - output.writeMessage(1, getRequest()); + output.writeMessage(1, getMessage()); } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(2, getConfiguration()); @@ -249,7 +249,7 @@ public int getSerializedSize() { size = 0; if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getRequest()); + .computeMessageSize(1, getMessage()); } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream @@ -279,10 +279,10 @@ public boolean equals(final java.lang.Object obj) { if (!getTenant() .equals(other.getTenant())) return false; - if (hasRequest() != other.hasRequest()) return false; - if (hasRequest()) { - if (!getRequest() - .equals(other.getRequest())) return false; + if (hasMessage() != other.hasMessage()) return false; + if (hasMessage()) { + if (!getMessage() + .equals(other.getMessage())) return false; } if (hasConfiguration() != other.hasConfiguration()) return false; if (hasConfiguration()) { @@ -307,9 +307,9 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + TENANT_FIELD_NUMBER; hash = (53 * hash) + getTenant().hashCode(); - if (hasRequest()) { - hash = (37 * hash) + REQUEST_FIELD_NUMBER; - hash = (53 * hash) + getRequest().hashCode(); + if (hasMessage()) { + hash = (37 * hash) + MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getMessage().hashCode(); } if (hasConfiguration()) { hash = (37 * hash) + CONFIGURATION_FIELD_NUMBER; @@ -455,7 +455,7 @@ private Builder( private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage .alwaysUseFieldBuilders) { - internalGetRequestFieldBuilder(); + internalGetMessageFieldBuilder(); internalGetConfigurationFieldBuilder(); internalGetMetadataFieldBuilder(); } @@ -465,10 +465,10 @@ public Builder clear() { super.clear(); bitField0_ = 0; tenant_ = ""; - request_ = null; - if (requestBuilder_ != null) { - requestBuilder_.dispose(); - requestBuilder_ = null; + message_ = null; + if (messageBuilder_ != null) { + messageBuilder_.dispose(); + messageBuilder_ = null; } configuration_ = null; if (configurationBuilder_ != null) { @@ -518,9 +518,9 @@ private void buildPartial0(io.a2a.grpc.SendMessageRequest result) { } int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000002) != 0)) { - result.request_ = requestBuilder_ == null - ? request_ - : requestBuilder_.build(); + result.message_ = messageBuilder_ == null + ? message_ + : messageBuilder_.build(); to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000004) != 0)) { @@ -555,8 +555,8 @@ public Builder mergeFrom(io.a2a.grpc.SendMessageRequest other) { bitField0_ |= 0x00000001; onChanged(); } - if (other.hasRequest()) { - mergeRequest(other.getRequest()); + if (other.hasMessage()) { + mergeMessage(other.getMessage()); } if (other.hasConfiguration()) { mergeConfiguration(other.getConfiguration()); @@ -592,7 +592,7 @@ public Builder mergeFrom( break; case 10: { input.readMessage( - internalGetRequestFieldBuilder().getBuilder(), + internalGetMessageFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000002; break; @@ -725,18 +725,18 @@ public Builder setTenantBytes( return this; } - private io.a2a.grpc.Message request_; + private io.a2a.grpc.Message message_; private com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> requestBuilder_; + io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> messageBuilder_; /** *
          * The message to send to the agent.
          * 
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; - * @return Whether the request field is set. + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return Whether the message field is set. */ - public boolean hasRequest() { + public boolean hasMessage() { return ((bitField0_ & 0x00000002) != 0); } /** @@ -744,14 +744,14 @@ public boolean hasRequest() { * The message to send to the agent. *
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; - * @return The request. + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The message. */ - public io.a2a.grpc.Message getRequest() { - if (requestBuilder_ == null) { - return request_ == null ? io.a2a.grpc.Message.getDefaultInstance() : request_; + public io.a2a.grpc.Message getMessage() { + if (messageBuilder_ == null) { + return message_ == null ? io.a2a.grpc.Message.getDefaultInstance() : message_; } else { - return requestBuilder_.getMessage(); + return messageBuilder_.getMessage(); } } /** @@ -759,16 +759,16 @@ public io.a2a.grpc.Message getRequest() { * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder setRequest(io.a2a.grpc.Message value) { - if (requestBuilder_ == null) { + public Builder setMessage(io.a2a.grpc.Message value) { + if (messageBuilder_ == null) { if (value == null) { throw new NullPointerException(); } - request_ = value; + message_ = value; } else { - requestBuilder_.setMessage(value); + messageBuilder_.setMessage(value); } bitField0_ |= 0x00000002; onChanged(); @@ -779,14 +779,14 @@ public Builder setRequest(io.a2a.grpc.Message value) { * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder setRequest( + public Builder setMessage( io.a2a.grpc.Message.Builder builderForValue) { - if (requestBuilder_ == null) { - request_ = builderForValue.build(); + if (messageBuilder_ == null) { + message_ = builderForValue.build(); } else { - requestBuilder_.setMessage(builderForValue.build()); + messageBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000002; onChanged(); @@ -797,21 +797,21 @@ public Builder setRequest( * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder mergeRequest(io.a2a.grpc.Message value) { - if (requestBuilder_ == null) { + public Builder mergeMessage(io.a2a.grpc.Message value) { + if (messageBuilder_ == null) { if (((bitField0_ & 0x00000002) != 0) && - request_ != null && - request_ != io.a2a.grpc.Message.getDefaultInstance()) { - getRequestBuilder().mergeFrom(value); + message_ != null && + message_ != io.a2a.grpc.Message.getDefaultInstance()) { + getMessageBuilder().mergeFrom(value); } else { - request_ = value; + message_ = value; } } else { - requestBuilder_.mergeFrom(value); + messageBuilder_.mergeFrom(value); } - if (request_ != null) { + if (message_ != null) { bitField0_ |= 0x00000002; onChanged(); } @@ -822,14 +822,14 @@ public Builder mergeRequest(io.a2a.grpc.Message value) { * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder clearRequest() { + public Builder clearMessage() { bitField0_ = (bitField0_ & ~0x00000002); - request_ = null; - if (requestBuilder_ != null) { - requestBuilder_.dispose(); - requestBuilder_ = null; + message_ = null; + if (messageBuilder_ != null) { + messageBuilder_.dispose(); + messageBuilder_ = null; } onChanged(); return this; @@ -839,26 +839,26 @@ public Builder clearRequest() { * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - public io.a2a.grpc.Message.Builder getRequestBuilder() { + public io.a2a.grpc.Message.Builder getMessageBuilder() { bitField0_ |= 0x00000002; onChanged(); - return internalGetRequestFieldBuilder().getBuilder(); + return internalGetMessageFieldBuilder().getBuilder(); } /** *
          * The message to send to the agent.
          * 
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - public io.a2a.grpc.MessageOrBuilder getRequestOrBuilder() { - if (requestBuilder_ != null) { - return requestBuilder_.getMessageOrBuilder(); + public io.a2a.grpc.MessageOrBuilder getMessageOrBuilder() { + if (messageBuilder_ != null) { + return messageBuilder_.getMessageOrBuilder(); } else { - return request_ == null ? - io.a2a.grpc.Message.getDefaultInstance() : request_; + return message_ == null ? + io.a2a.grpc.Message.getDefaultInstance() : message_; } } /** @@ -866,20 +866,20 @@ public io.a2a.grpc.MessageOrBuilder getRequestOrBuilder() { * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ private com.google.protobuf.SingleFieldBuilder< io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> - internalGetRequestFieldBuilder() { - if (requestBuilder_ == null) { - requestBuilder_ = new com.google.protobuf.SingleFieldBuilder< + internalGetMessageFieldBuilder() { + if (messageBuilder_ == null) { + messageBuilder_ = new com.google.protobuf.SingleFieldBuilder< io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder>( - getRequest(), + getMessage(), getParentForChildren(), isClean()); - request_ = null; + message_ = null; } - return requestBuilder_; + return messageBuilder_; } private io.a2a.grpc.SendMessageConfiguration configuration_; diff --git a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequestOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequestOrBuilder.java index 5040d6562..de2e6cc12 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequestOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageRequestOrBuilder.java @@ -35,27 +35,27 @@ public interface SendMessageRequestOrBuilder extends * The message to send to the agent. * * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; - * @return Whether the request field is set. + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return Whether the message field is set. */ - boolean hasRequest(); + boolean hasMessage(); /** *
        * The message to send to the agent.
        * 
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; - * @return The request. + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return The message. */ - io.a2a.grpc.Message getRequest(); + io.a2a.grpc.Message getMessage(); /** *
        * The message to send to the agent.
        * 
    * - * .a2a.v1.Message request = 1 [json_name = "message", (.google.api.field_behavior) = REQUIRED]; + * .a2a.v1.Message message = 1 [(.google.api.field_behavior) = REQUIRED]; */ - io.a2a.grpc.MessageOrBuilder getRequestOrBuilder(); + io.a2a.grpc.MessageOrBuilder getMessageOrBuilder(); /** *
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponse.java b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponse.java
    index 0fe457f59..466f2206a 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponse.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponse.java
    @@ -55,7 +55,7 @@ public enum PayloadCase
           implements com.google.protobuf.Internal.EnumLite,
               com.google.protobuf.AbstractMessage.InternalOneOfEnum {
         TASK(1),
    -    MSG(2),
    +    MESSAGE(2),
         PAYLOAD_NOT_SET(0);
         private final int value;
         private PayloadCase(int value) {
    @@ -74,7 +74,7 @@ public static PayloadCase valueOf(int value) {
         public static PayloadCase forNumber(int value) {
           switch (value) {
             case 1: return TASK;
    -        case 2: return MSG;
    +        case 2: return MESSAGE;
             case 0: return PAYLOAD_NOT_SET;
             default: return null;
           }
    @@ -121,31 +121,31 @@ public io.a2a.grpc.TaskOrBuilder getTaskOrBuilder() {
         return io.a2a.grpc.Task.getDefaultInstance();
       }
     
    -  public static final int MSG_FIELD_NUMBER = 2;
    +  public static final int MESSAGE_FIELD_NUMBER = 2;
       /**
    -   * .a2a.v1.Message msg = 2 [json_name = "message"];
    -   * @return Whether the msg field is set.
    +   * .a2a.v1.Message message = 2;
    +   * @return Whether the message field is set.
        */
       @java.lang.Override
    -  public boolean hasMsg() {
    +  public boolean hasMessage() {
         return payloadCase_ == 2;
       }
       /**
    -   * .a2a.v1.Message msg = 2 [json_name = "message"];
    -   * @return The msg.
    +   * .a2a.v1.Message message = 2;
    +   * @return The message.
        */
       @java.lang.Override
    -  public io.a2a.grpc.Message getMsg() {
    +  public io.a2a.grpc.Message getMessage() {
         if (payloadCase_ == 2) {
            return (io.a2a.grpc.Message) payload_;
         }
         return io.a2a.grpc.Message.getDefaultInstance();
       }
       /**
    -   * .a2a.v1.Message msg = 2 [json_name = "message"];
    +   * .a2a.v1.Message message = 2;
        */
       @java.lang.Override
    -  public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() {
    +  public io.a2a.grpc.MessageOrBuilder getMessageOrBuilder() {
         if (payloadCase_ == 2) {
            return (io.a2a.grpc.Message) payload_;
         }
    @@ -211,8 +211,8 @@ public boolean equals(final java.lang.Object obj) {
                 .equals(other.getTask())) return false;
             break;
           case 2:
    -        if (!getMsg()
    -            .equals(other.getMsg())) return false;
    +        if (!getMessage()
    +            .equals(other.getMessage())) return false;
             break;
           case 0:
           default:
    @@ -234,8 +234,8 @@ public int hashCode() {
             hash = (53 * hash) + getTask().hashCode();
             break;
           case 2:
    -        hash = (37 * hash) + MSG_FIELD_NUMBER;
    -        hash = (53 * hash) + getMsg().hashCode();
    +        hash = (37 * hash) + MESSAGE_FIELD_NUMBER;
    +        hash = (53 * hash) + getMessage().hashCode();
             break;
           case 0:
           default:
    @@ -379,8 +379,8 @@ public Builder clear() {
           if (taskBuilder_ != null) {
             taskBuilder_.clear();
           }
    -      if (msgBuilder_ != null) {
    -        msgBuilder_.clear();
    +      if (messageBuilder_ != null) {
    +        messageBuilder_.clear();
           }
           payloadCase_ = 0;
           payload_ = null;
    @@ -428,8 +428,8 @@ private void buildPartialOneofs(io.a2a.grpc.SendMessageResponse result) {
             result.payload_ = taskBuilder_.build();
           }
           if (payloadCase_ == 2 &&
    -          msgBuilder_ != null) {
    -        result.payload_ = msgBuilder_.build();
    +          messageBuilder_ != null) {
    +        result.payload_ = messageBuilder_.build();
           }
         }
     
    @@ -450,8 +450,8 @@ public Builder mergeFrom(io.a2a.grpc.SendMessageResponse other) {
               mergeTask(other.getTask());
               break;
             }
    -        case MSG: {
    -          mergeMsg(other.getMsg());
    +        case MESSAGE: {
    +          mergeMessage(other.getMessage());
               break;
             }
             case PAYLOAD_NOT_SET: {
    @@ -493,7 +493,7 @@ public Builder mergeFrom(
                 } // case 10
                 case 18: {
                   input.readMessage(
    -                  internalGetMsgFieldBuilder().getBuilder(),
    +                  internalGetMessageFieldBuilder().getBuilder(),
                       extensionRegistry);
                   payloadCase_ = 2;
                   break;
    @@ -673,68 +673,68 @@ public io.a2a.grpc.TaskOrBuilder getTaskOrBuilder() {
         }
     
         private com.google.protobuf.SingleFieldBuilder<
    -        io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> msgBuilder_;
    +        io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> messageBuilder_;
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    -     * @return Whether the msg field is set.
    +     * .a2a.v1.Message message = 2;
    +     * @return Whether the message field is set.
          */
         @java.lang.Override
    -    public boolean hasMsg() {
    +    public boolean hasMessage() {
           return payloadCase_ == 2;
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    -     * @return The msg.
    +     * .a2a.v1.Message message = 2;
    +     * @return The message.
          */
         @java.lang.Override
    -    public io.a2a.grpc.Message getMsg() {
    -      if (msgBuilder_ == null) {
    +    public io.a2a.grpc.Message getMessage() {
    +      if (messageBuilder_ == null) {
             if (payloadCase_ == 2) {
               return (io.a2a.grpc.Message) payload_;
             }
             return io.a2a.grpc.Message.getDefaultInstance();
           } else {
             if (payloadCase_ == 2) {
    -          return msgBuilder_.getMessage();
    +          return messageBuilder_.getMessage();
             }
             return io.a2a.grpc.Message.getDefaultInstance();
           }
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
    -    public Builder setMsg(io.a2a.grpc.Message value) {
    -      if (msgBuilder_ == null) {
    +    public Builder setMessage(io.a2a.grpc.Message value) {
    +      if (messageBuilder_ == null) {
             if (value == null) {
               throw new NullPointerException();
             }
             payload_ = value;
             onChanged();
           } else {
    -        msgBuilder_.setMessage(value);
    +        messageBuilder_.setMessage(value);
           }
           payloadCase_ = 2;
           return this;
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
    -    public Builder setMsg(
    +    public Builder setMessage(
             io.a2a.grpc.Message.Builder builderForValue) {
    -      if (msgBuilder_ == null) {
    +      if (messageBuilder_ == null) {
             payload_ = builderForValue.build();
             onChanged();
           } else {
    -        msgBuilder_.setMessage(builderForValue.build());
    +        messageBuilder_.setMessage(builderForValue.build());
           }
           payloadCase_ = 2;
           return this;
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
    -    public Builder mergeMsg(io.a2a.grpc.Message value) {
    -      if (msgBuilder_ == null) {
    +    public Builder mergeMessage(io.a2a.grpc.Message value) {
    +      if (messageBuilder_ == null) {
             if (payloadCase_ == 2 &&
                 payload_ != io.a2a.grpc.Message.getDefaultInstance()) {
               payload_ = io.a2a.grpc.Message.newBuilder((io.a2a.grpc.Message) payload_)
    @@ -745,19 +745,19 @@ public Builder mergeMsg(io.a2a.grpc.Message value) {
             onChanged();
           } else {
             if (payloadCase_ == 2) {
    -          msgBuilder_.mergeFrom(value);
    +          messageBuilder_.mergeFrom(value);
             } else {
    -          msgBuilder_.setMessage(value);
    +          messageBuilder_.setMessage(value);
             }
           }
           payloadCase_ = 2;
           return this;
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
    -    public Builder clearMsg() {
    -      if (msgBuilder_ == null) {
    +    public Builder clearMessage() {
    +      if (messageBuilder_ == null) {
             if (payloadCase_ == 2) {
               payloadCase_ = 0;
               payload_ = null;
    @@ -768,23 +768,23 @@ public Builder clearMsg() {
               payloadCase_ = 0;
               payload_ = null;
             }
    -        msgBuilder_.clear();
    +        messageBuilder_.clear();
           }
           return this;
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
    -    public io.a2a.grpc.Message.Builder getMsgBuilder() {
    -      return internalGetMsgFieldBuilder().getBuilder();
    +    public io.a2a.grpc.Message.Builder getMessageBuilder() {
    +      return internalGetMessageFieldBuilder().getBuilder();
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
         @java.lang.Override
    -    public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() {
    -      if ((payloadCase_ == 2) && (msgBuilder_ != null)) {
    -        return msgBuilder_.getMessageOrBuilder();
    +    public io.a2a.grpc.MessageOrBuilder getMessageOrBuilder() {
    +      if ((payloadCase_ == 2) && (messageBuilder_ != null)) {
    +        return messageBuilder_.getMessageOrBuilder();
           } else {
             if (payloadCase_ == 2) {
               return (io.a2a.grpc.Message) payload_;
    @@ -793,16 +793,16 @@ public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() {
           }
         }
         /**
    -     * .a2a.v1.Message msg = 2 [json_name = "message"];
    +     * .a2a.v1.Message message = 2;
          */
         private com.google.protobuf.SingleFieldBuilder<
             io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> 
    -        internalGetMsgFieldBuilder() {
    -      if (msgBuilder_ == null) {
    +        internalGetMessageFieldBuilder() {
    +      if (messageBuilder_ == null) {
             if (!(payloadCase_ == 2)) {
               payload_ = io.a2a.grpc.Message.getDefaultInstance();
             }
    -        msgBuilder_ = new com.google.protobuf.SingleFieldBuilder<
    +        messageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                 io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder>(
                     (io.a2a.grpc.Message) payload_,
                     getParentForChildren(),
    @@ -811,7 +811,7 @@ public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() {
           }
           payloadCase_ = 2;
           onChanged();
    -      return msgBuilder_;
    +      return messageBuilder_;
         }
     
         // @@protoc_insertion_point(builder_scope:a2a.v1.SendMessageResponse)
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponseOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponseOrBuilder.java
    index 40a838920..355131b71 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponseOrBuilder.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/SendMessageResponseOrBuilder.java
    @@ -26,19 +26,19 @@ public interface SendMessageResponseOrBuilder extends
       io.a2a.grpc.TaskOrBuilder getTaskOrBuilder();
     
       /**
    -   * .a2a.v1.Message msg = 2 [json_name = "message"];
    -   * @return Whether the msg field is set.
    +   * .a2a.v1.Message message = 2;
    +   * @return Whether the message field is set.
        */
    -  boolean hasMsg();
    +  boolean hasMessage();
       /**
    -   * .a2a.v1.Message msg = 2 [json_name = "message"];
    -   * @return The msg.
    +   * .a2a.v1.Message message = 2;
    +   * @return The message.
        */
    -  io.a2a.grpc.Message getMsg();
    +  io.a2a.grpc.Message getMessage();
       /**
    -   * .a2a.v1.Message msg = 2 [json_name = "message"];
    +   * .a2a.v1.Message message = 2;
        */
    -  io.a2a.grpc.MessageOrBuilder getMsgOrBuilder();
    +  io.a2a.grpc.MessageOrBuilder getMessageOrBuilder();
     
       io.a2a.grpc.SendMessageResponse.PayloadCase getPayloadCase();
     }
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/StreamResponse.java b/spec-grpc/src/main/java/io/a2a/grpc/StreamResponse.java
    index 139650483..3d27db5ef 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/StreamResponse.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/StreamResponse.java
    @@ -55,7 +55,7 @@ public enum PayloadCase
           implements com.google.protobuf.Internal.EnumLite,
               com.google.protobuf.AbstractMessage.InternalOneOfEnum {
         TASK(1),
    -    MSG(2),
    +    MESSAGE(2),
         STATUS_UPDATE(3),
         ARTIFACT_UPDATE(4),
         PAYLOAD_NOT_SET(0);
    @@ -76,7 +76,7 @@ public static PayloadCase valueOf(int value) {
         public static PayloadCase forNumber(int value) {
           switch (value) {
             case 1: return TASK;
    -        case 2: return MSG;
    +        case 2: return MESSAGE;
             case 3: return STATUS_UPDATE;
             case 4: return ARTIFACT_UPDATE;
             case 0: return PAYLOAD_NOT_SET;
    @@ -137,17 +137,17 @@ public io.a2a.grpc.TaskOrBuilder getTaskOrBuilder() {
         return io.a2a.grpc.Task.getDefaultInstance();
       }
     
    -  public static final int MSG_FIELD_NUMBER = 2;
    +  public static final int MESSAGE_FIELD_NUMBER = 2;
       /**
        * 
        * A Message object containing a message from the agent.
        * 
    * - * .a2a.v1.Message msg = 2 [json_name = "message"]; - * @return Whether the msg field is set. + * .a2a.v1.Message message = 2; + * @return Whether the message field is set. */ @java.lang.Override - public boolean hasMsg() { + public boolean hasMessage() { return payloadCase_ == 2; } /** @@ -155,11 +155,11 @@ public boolean hasMsg() { * A Message object containing a message from the agent. *
    * - * .a2a.v1.Message msg = 2 [json_name = "message"]; - * @return The msg. + * .a2a.v1.Message message = 2; + * @return The message. */ @java.lang.Override - public io.a2a.grpc.Message getMsg() { + public io.a2a.grpc.Message getMessage() { if (payloadCase_ == 2) { return (io.a2a.grpc.Message) payload_; } @@ -170,10 +170,10 @@ public io.a2a.grpc.Message getMsg() { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ @java.lang.Override - public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() { + public io.a2a.grpc.MessageOrBuilder getMessageOrBuilder() { if (payloadCase_ == 2) { return (io.a2a.grpc.Message) payload_; } @@ -339,8 +339,8 @@ public boolean equals(final java.lang.Object obj) { .equals(other.getTask())) return false; break; case 2: - if (!getMsg() - .equals(other.getMsg())) return false; + if (!getMessage() + .equals(other.getMessage())) return false; break; case 3: if (!getStatusUpdate() @@ -370,8 +370,8 @@ public int hashCode() { hash = (53 * hash) + getTask().hashCode(); break; case 2: - hash = (37 * hash) + MSG_FIELD_NUMBER; - hash = (53 * hash) + getMsg().hashCode(); + hash = (37 * hash) + MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getMessage().hashCode(); break; case 3: hash = (37 * hash) + STATUS_UPDATE_FIELD_NUMBER; @@ -523,8 +523,8 @@ public Builder clear() { if (taskBuilder_ != null) { taskBuilder_.clear(); } - if (msgBuilder_ != null) { - msgBuilder_.clear(); + if (messageBuilder_ != null) { + messageBuilder_.clear(); } if (statusUpdateBuilder_ != null) { statusUpdateBuilder_.clear(); @@ -578,8 +578,8 @@ private void buildPartialOneofs(io.a2a.grpc.StreamResponse result) { result.payload_ = taskBuilder_.build(); } if (payloadCase_ == 2 && - msgBuilder_ != null) { - result.payload_ = msgBuilder_.build(); + messageBuilder_ != null) { + result.payload_ = messageBuilder_.build(); } if (payloadCase_ == 3 && statusUpdateBuilder_ != null) { @@ -608,8 +608,8 @@ public Builder mergeFrom(io.a2a.grpc.StreamResponse other) { mergeTask(other.getTask()); break; } - case MSG: { - mergeMsg(other.getMsg()); + case MESSAGE: { + mergeMessage(other.getMessage()); break; } case STATUS_UPDATE: { @@ -659,7 +659,7 @@ public Builder mergeFrom( } // case 10 case 18: { input.readMessage( - internalGetMsgFieldBuilder().getBuilder(), + internalGetMessageFieldBuilder().getBuilder(), extensionRegistry); payloadCase_ = 2; break; @@ -889,17 +889,17 @@ public io.a2a.grpc.TaskOrBuilder getTaskOrBuilder() { } private com.google.protobuf.SingleFieldBuilder< - io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> msgBuilder_; + io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> messageBuilder_; /** *
          * A Message object containing a message from the agent.
          * 
    * - * .a2a.v1.Message msg = 2 [json_name = "message"]; - * @return Whether the msg field is set. + * .a2a.v1.Message message = 2; + * @return Whether the message field is set. */ @java.lang.Override - public boolean hasMsg() { + public boolean hasMessage() { return payloadCase_ == 2; } /** @@ -907,19 +907,19 @@ public boolean hasMsg() { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; - * @return The msg. + * .a2a.v1.Message message = 2; + * @return The message. */ @java.lang.Override - public io.a2a.grpc.Message getMsg() { - if (msgBuilder_ == null) { + public io.a2a.grpc.Message getMessage() { + if (messageBuilder_ == null) { if (payloadCase_ == 2) { return (io.a2a.grpc.Message) payload_; } return io.a2a.grpc.Message.getDefaultInstance(); } else { if (payloadCase_ == 2) { - return msgBuilder_.getMessage(); + return messageBuilder_.getMessage(); } return io.a2a.grpc.Message.getDefaultInstance(); } @@ -929,17 +929,17 @@ public io.a2a.grpc.Message getMsg() { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ - public Builder setMsg(io.a2a.grpc.Message value) { - if (msgBuilder_ == null) { + public Builder setMessage(io.a2a.grpc.Message value) { + if (messageBuilder_ == null) { if (value == null) { throw new NullPointerException(); } payload_ = value; onChanged(); } else { - msgBuilder_.setMessage(value); + messageBuilder_.setMessage(value); } payloadCase_ = 2; return this; @@ -949,15 +949,15 @@ public Builder setMsg(io.a2a.grpc.Message value) { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ - public Builder setMsg( + public Builder setMessage( io.a2a.grpc.Message.Builder builderForValue) { - if (msgBuilder_ == null) { + if (messageBuilder_ == null) { payload_ = builderForValue.build(); onChanged(); } else { - msgBuilder_.setMessage(builderForValue.build()); + messageBuilder_.setMessage(builderForValue.build()); } payloadCase_ = 2; return this; @@ -967,10 +967,10 @@ public Builder setMsg( * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ - public Builder mergeMsg(io.a2a.grpc.Message value) { - if (msgBuilder_ == null) { + public Builder mergeMessage(io.a2a.grpc.Message value) { + if (messageBuilder_ == null) { if (payloadCase_ == 2 && payload_ != io.a2a.grpc.Message.getDefaultInstance()) { payload_ = io.a2a.grpc.Message.newBuilder((io.a2a.grpc.Message) payload_) @@ -981,9 +981,9 @@ public Builder mergeMsg(io.a2a.grpc.Message value) { onChanged(); } else { if (payloadCase_ == 2) { - msgBuilder_.mergeFrom(value); + messageBuilder_.mergeFrom(value); } else { - msgBuilder_.setMessage(value); + messageBuilder_.setMessage(value); } } payloadCase_ = 2; @@ -994,10 +994,10 @@ public Builder mergeMsg(io.a2a.grpc.Message value) { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ - public Builder clearMsg() { - if (msgBuilder_ == null) { + public Builder clearMessage() { + if (messageBuilder_ == null) { if (payloadCase_ == 2) { payloadCase_ = 0; payload_ = null; @@ -1008,7 +1008,7 @@ public Builder clearMsg() { payloadCase_ = 0; payload_ = null; } - msgBuilder_.clear(); + messageBuilder_.clear(); } return this; } @@ -1017,22 +1017,22 @@ public Builder clearMsg() { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ - public io.a2a.grpc.Message.Builder getMsgBuilder() { - return internalGetMsgFieldBuilder().getBuilder(); + public io.a2a.grpc.Message.Builder getMessageBuilder() { + return internalGetMessageFieldBuilder().getBuilder(); } /** *
          * A Message object containing a message from the agent.
          * 
    * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ @java.lang.Override - public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() { - if ((payloadCase_ == 2) && (msgBuilder_ != null)) { - return msgBuilder_.getMessageOrBuilder(); + public io.a2a.grpc.MessageOrBuilder getMessageOrBuilder() { + if ((payloadCase_ == 2) && (messageBuilder_ != null)) { + return messageBuilder_.getMessageOrBuilder(); } else { if (payloadCase_ == 2) { return (io.a2a.grpc.Message) payload_; @@ -1045,16 +1045,16 @@ public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() { * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ private com.google.protobuf.SingleFieldBuilder< io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder> - internalGetMsgFieldBuilder() { - if (msgBuilder_ == null) { + internalGetMessageFieldBuilder() { + if (messageBuilder_ == null) { if (!(payloadCase_ == 2)) { payload_ = io.a2a.grpc.Message.getDefaultInstance(); } - msgBuilder_ = new com.google.protobuf.SingleFieldBuilder< + messageBuilder_ = new com.google.protobuf.SingleFieldBuilder< io.a2a.grpc.Message, io.a2a.grpc.Message.Builder, io.a2a.grpc.MessageOrBuilder>( (io.a2a.grpc.Message) payload_, getParentForChildren(), @@ -1063,7 +1063,7 @@ public io.a2a.grpc.MessageOrBuilder getMsgOrBuilder() { } payloadCase_ = 2; onChanged(); - return msgBuilder_; + return messageBuilder_; } private com.google.protobuf.SingleFieldBuilder< diff --git a/spec-grpc/src/main/java/io/a2a/grpc/StreamResponseOrBuilder.java b/spec-grpc/src/main/java/io/a2a/grpc/StreamResponseOrBuilder.java index d6596f26d..5688ed06b 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/StreamResponseOrBuilder.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/StreamResponseOrBuilder.java @@ -42,27 +42,27 @@ public interface StreamResponseOrBuilder extends * A Message object containing a message from the agent. * * - * .a2a.v1.Message msg = 2 [json_name = "message"]; - * @return Whether the msg field is set. + * .a2a.v1.Message message = 2; + * @return Whether the message field is set. */ - boolean hasMsg(); + boolean hasMessage(); /** *
        * A Message object containing a message from the agent.
        * 
    * - * .a2a.v1.Message msg = 2 [json_name = "message"]; - * @return The msg. + * .a2a.v1.Message message = 2; + * @return The message. */ - io.a2a.grpc.Message getMsg(); + io.a2a.grpc.Message getMessage(); /** *
        * A Message object containing a message from the agent.
        * 
    * - * .a2a.v1.Message msg = 2 [json_name = "message"]; + * .a2a.v1.Message message = 2; */ - io.a2a.grpc.MessageOrBuilder getMsgOrBuilder(); + io.a2a.grpc.MessageOrBuilder getMessageOrBuilder(); /** *
    diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/A2ACommonFieldMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/A2ACommonFieldMapper.java
    index 723df2e53..0acdc5d3e 100644
    --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/A2ACommonFieldMapper.java
    +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/A2ACommonFieldMapper.java
    @@ -370,6 +370,44 @@ default Instant millisToInstant(long millis) {
             return millis > 0L ? Instant.ofEpochMilli(millis) : null;
         }
     
    +    // ========================================================================
    +    // Instant ↔ Timestamp Conversions (for Timestamp timestamp fields)
    +    // ========================================================================
    +    /**
    +     * Converts domain Instant to protobuf Timestamp.
    +     * 

    + * Use this with {@code @Mapping(qualifiedByName = "instantToProtoTimestamp")}. + * + * @param instant the domain Instant + * @return protobuf Timestamp, or default instance if input is null + */ + @Named("instantToProtoTimestamp") + default Timestamp instantToProtoTimestamp(Instant instant) { + if (instant == null) { + return Timestamp.getDefaultInstance(); + } + return Timestamp.newBuilder() + .setSeconds(instant.getEpochSecond()) + .setNanos(instant.getNano()) + .build(); + } + + /** + * Converts protobuf Timestamp to domain Instant. + *

    + * Use this with {@code @Mapping(qualifiedByName = "protoTimestampToInstant")}. + * + * @param timestamp the protobuf Timestamp + * @return Instant, or null if input is null/default + */ + @Named("protoTimestampToInstant") + default Instant protoTimestampToInstant(Timestamp timestamp) { + if (timestamp == null || timestamp.equals(Timestamp.getDefaultInstance())) { + return null; + } + return Instant.ofEpochSecond(timestamp.getSeconds(), timestamp.getNanos()); + } + // ======================================================================== // Enum Conversions (handling UNSPECIFIED/UNKNOWN) // ======================================================================== diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCapabilitiesMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCapabilitiesMapper.java index a8216fec8..337ea8de6 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCapabilitiesMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCapabilitiesMapper.java @@ -2,6 +2,7 @@ import org.mapstruct.CollectionMappingStrategy; import org.mapstruct.Mapper; +import org.mapstruct.Mapping; /** * Mapper between {@link io.a2a.spec.AgentCapabilities} and {@link io.a2a.grpc.AgentCapabilities}. diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCardMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCardMapper.java index 7a27cb57d..97b9ed0a1 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCardMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/AgentCardMapper.java @@ -22,10 +22,6 @@ public interface AgentCardMapper { AgentCardMapper INSTANCE = A2AMappers.getMapper(AgentCardMapper.class); - // Deprecated proto fields - not present in spec API (removed in 1.0.0) - @Mapping(target = "url", ignore = true) - @Mapping(target = "preferredTransport", ignore = true) - @Mapping(target = "additionalInterfaces", ignore = true) @Mapping(target = "provider", source = "provider", conditionExpression = "java(domain.provider() != null)") @Mapping(target = "documentationUrl", source = "documentationUrl", conditionExpression = "java(domain.documentationUrl() != null)") @Mapping(target = "iconUrl", source = "iconUrl", conditionExpression = "java(domain.iconUrl() != null)") diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/AuthorizationCodeOAuthFlowMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/AuthorizationCodeOAuthFlowMapper.java index 09fdc3184..d59a3e10a 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/AuthorizationCodeOAuthFlowMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/AuthorizationCodeOAuthFlowMapper.java @@ -2,6 +2,7 @@ import org.mapstruct.CollectionMappingStrategy; import org.mapstruct.Mapper; +import org.mapstruct.Mapping; /** * Mapper between {@link io.a2a.spec.AuthorizationCodeOAuthFlow} and {@link io.a2a.grpc.AuthorizationCodeOAuthFlow}. diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/ImplicitOAuthFlowMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/ImplicitOAuthFlowMapper.java deleted file mode 100644 index 99f0b7854..000000000 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/ImplicitOAuthFlowMapper.java +++ /dev/null @@ -1,18 +0,0 @@ -package io.a2a.grpc.mapper; - -import org.mapstruct.CollectionMappingStrategy; -import org.mapstruct.Mapper; - -/** - * Mapper between {@link io.a2a.spec.ImplicitOAuthFlow} and {@link io.a2a.grpc.ImplicitOAuthFlow}. - */ -@Mapper(config = A2AProtoMapperConfig.class, - collectionMappingStrategy = CollectionMappingStrategy.ADDER_PREFERRED) -public interface ImplicitOAuthFlowMapper { - - ImplicitOAuthFlowMapper INSTANCE = A2AMappers.getMapper(ImplicitOAuthFlowMapper.class); - - io.a2a.grpc.ImplicitOAuthFlow toProto(io.a2a.spec.ImplicitOAuthFlow domain); - - io.a2a.spec.ImplicitOAuthFlow fromProto(io.a2a.grpc.ImplicitOAuthFlow proto); -} diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/ListTasksParamsMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/ListTasksParamsMapper.java index cdb501d9a..06d4c2dd4 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/ListTasksParamsMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/ListTasksParamsMapper.java @@ -26,7 +26,7 @@ public interface ListTasksParamsMapper { @Mapping(target = "pageSize", source = "pageSize", conditionExpression = "java(params.pageSize() != null)") @Mapping(target = "pageToken", source = "pageToken", conditionExpression = "java(params.pageToken() != null)") @Mapping(target = "historyLength", source = "historyLength", conditionExpression = "java(params.historyLength() != null)") - @Mapping(target = "lastUpdatedAfter", source = "lastUpdatedAfter", qualifiedByName = "instantToMillis") + @Mapping(target = "statusTimestampAfter", source = "statusTimestampAfter", qualifiedByName = "instantToProtoTimestamp") @Mapping(target = "includeArtifacts", source = "includeArtifacts", conditionExpression = "java(params.includeArtifacts() != null)") ListTasksRequest toProto(io.a2a.spec.ListTasksParams params); @@ -43,7 +43,7 @@ public interface ListTasksParamsMapper { @Mapping(target = "pageToken", source = "pageToken", qualifiedByName = "emptyToNull") // historyLength: Check if field is set using hasHistoryLength() for consistency with pageSize @Mapping(target = "historyLength", expression = "java(request.hasHistoryLength() ? request.getHistoryLength() : null)") - @Mapping(target = "lastUpdatedAfter", source = "lastUpdatedAfter", qualifiedByName = "millisToInstant") + @Mapping(target = "statusTimestampAfter", source = "statusTimestampAfter", qualifiedByName = "protoTimestampToInstant") @Mapping(target = "includeArtifacts", source = "includeArtifacts", qualifiedByName = "falseToNull") io.a2a.spec.ListTasksParams fromProto(ListTasksRequest request); } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/MessageSendParamsMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/MessageSendParamsMapper.java index 759fc0fef..11885ac11 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/MessageSendParamsMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/MessageSendParamsMapper.java @@ -18,20 +18,18 @@ public interface MessageSendParamsMapper { /** * Converts domain MessageSendParams to proto SendMessageRequest. - * Maps domain "message" field to proto "request" field. + * Maps domain "message" field to proto "message" field. */ - @Mapping(target = "request", source = "message") @Mapping(target = "configuration", source = "configuration", conditionExpression = "java(domain.configuration() != null)") @Mapping(target = "metadata", source = "metadata", qualifiedByName = "metadataToProto") io.a2a.grpc.SendMessageRequest toProto(MessageSendParams domain); /** * Converts proto SendMessageRequest to domain MessageSendParams. - * Maps proto "request" field to domain "message" field. + * Maps proto "message" field to domain "message" field. * Uses Builder pattern for record construction. */ @BeanMapping(builder = @Builder(buildMethod = "build")) - @Mapping(target = "message", source = "request") @Mapping(target = "metadata", source = "metadata", qualifiedByName = "metadataFromProto") MessageSendParams fromProto(io.a2a.grpc.SendMessageRequest proto); } diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/OAuthFlowsMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/OAuthFlowsMapper.java index 6af0e28ce..e919b50d6 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/OAuthFlowsMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/OAuthFlowsMapper.java @@ -2,6 +2,7 @@ import org.mapstruct.CollectionMappingStrategy; import org.mapstruct.Mapper; +import org.mapstruct.Mapping; /** * Mapper between {@link io.a2a.spec.OAuthFlows} and {@link io.a2a.grpc.OAuthFlows}. @@ -10,9 +11,7 @@ collectionMappingStrategy = CollectionMappingStrategy.ADDER_PREFERRED, uses = { AuthorizationCodeOAuthFlowMapper.class, - ClientCredentialsOAuthFlowMapper.class, - ImplicitOAuthFlowMapper.class, - PasswordOAuthFlowMapper.class + ClientCredentialsOAuthFlowMapper.class }) public interface OAuthFlowsMapper { diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/PasswordOAuthFlowMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/PasswordOAuthFlowMapper.java deleted file mode 100644 index 84b6e1bdf..000000000 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/PasswordOAuthFlowMapper.java +++ /dev/null @@ -1,18 +0,0 @@ -package io.a2a.grpc.mapper; - -import org.mapstruct.CollectionMappingStrategy; -import org.mapstruct.Mapper; - -/** - * Mapper between {@link io.a2a.spec.PasswordOAuthFlow} and {@link io.a2a.grpc.PasswordOAuthFlow}. - */ -@Mapper(config = A2AProtoMapperConfig.class, - collectionMappingStrategy = CollectionMappingStrategy.ADDER_PREFERRED) -public interface PasswordOAuthFlowMapper { - - PasswordOAuthFlowMapper INSTANCE = A2AMappers.getMapper(PasswordOAuthFlowMapper.class); - - io.a2a.grpc.PasswordOAuthFlow toProto(io.a2a.spec.PasswordOAuthFlow domain); - - io.a2a.spec.PasswordOAuthFlow fromProto(io.a2a.grpc.PasswordOAuthFlow proto); -} diff --git a/spec-grpc/src/main/java/io/a2a/grpc/mapper/StreamResponseMapper.java b/spec-grpc/src/main/java/io/a2a/grpc/mapper/StreamResponseMapper.java index 2b91beff0..07eacb148 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/mapper/StreamResponseMapper.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/mapper/StreamResponseMapper.java @@ -45,7 +45,7 @@ default io.a2a.grpc.StreamResponse toProto(StreamingEventKind domain) { .setTask(TaskMapper.INSTANCE.toProto((Task) domain)) .build(); case Message.STREAMING_EVENT_ID -> io.a2a.grpc.StreamResponse.newBuilder() - .setMsg(MessageMapper.INSTANCE.toProto((Message) domain)) + .setMessage(MessageMapper.INSTANCE.toProto((Message) domain)) .build(); case TaskStatusUpdateEvent.STREAMING_EVENT_ID -> io.a2a.grpc.StreamResponse.newBuilder() .setStatusUpdate(TaskStatusUpdateEventMapper.INSTANCE.toProto((TaskStatusUpdateEvent) domain)) @@ -74,8 +74,8 @@ default StreamingEventKind fromProto(io.a2a.grpc.StreamResponse proto) { return switch (proto.getPayloadCase()) { case TASK -> TaskMapper.INSTANCE.fromProto(proto.getTask()); - case MSG -> - MessageMapper.INSTANCE.fromProto(proto.getMsg()); + case MESSAGE -> + MessageMapper.INSTANCE.fromProto(proto.getMessage()); case STATUS_UPDATE -> TaskStatusUpdateEventMapper.INSTANCE.fromProto(proto.getStatusUpdate()); case ARTIFACT_UPDATE -> diff --git a/spec-grpc/src/main/java/io/a2a/grpc/utils/JSONRPCUtils.java b/spec-grpc/src/main/java/io/a2a/grpc/utils/JSONRPCUtils.java index c7d1df72f..1692ae3a5 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/utils/JSONRPCUtils.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/utils/JSONRPCUtils.java @@ -1,7 +1,7 @@ package io.a2a.grpc.utils; import static io.a2a.spec.A2AErrorCodes.CONTENT_TYPE_NOT_SUPPORTED_ERROR_CODE; -import static io.a2a.spec.A2AErrorCodes.EXTENDED_CARD_NOT_CONFIGURED_ERROR_CODE; +import static io.a2a.spec.A2AErrorCodes.EXTENDED_AGENT_CARD_NOT_CONFIGURED_ERROR_CODE; import static io.a2a.spec.A2AErrorCodes.EXTENSION_SUPPORT_REQUIRED_ERROR; import static io.a2a.spec.A2AErrorCodes.INTERNAL_ERROR_CODE; import static io.a2a.spec.A2AErrorCodes.INVALID_AGENT_RESPONSE_ERROR_CODE; @@ -48,8 +48,8 @@ import io.a2a.jsonrpc.common.wrappers.CancelTaskResponse; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigResponse; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardRequest; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardResponse; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardRequest; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskRequest; @@ -66,7 +66,7 @@ import io.a2a.jsonrpc.common.wrappers.SubscribeToTaskRequest; import io.a2a.spec.A2AError; import io.a2a.spec.ContentTypeNotSupportedError; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.ExtensionSupportRequiredError; import io.a2a.spec.InvalidAgentResponseError; import io.a2a.spec.InvalidParamsError; @@ -245,7 +245,7 @@ private static A2ARequest parseMethodRequest(String version, Object id, Strin return new DeleteTaskPushNotificationConfigRequest(version, id, ProtoUtils.FromProto.deleteTaskPushNotificationConfigParams(builder)); } case GET_EXTENDED_AGENT_CARD_METHOD -> { - return new GetAuthenticatedExtendedCardRequest(version, id); + return new GetExtendedAgentCardRequest(version, id); } case SEND_STREAMING_MESSAGE_METHOD -> { io.a2a.grpc.SendMessageRequest.Builder builder = io.a2a.grpc.SendMessageRequest.newBuilder(); @@ -314,8 +314,8 @@ public static A2AResponse parseResponseBody(String body, String method) throw case SEND_MESSAGE_METHOD -> { io.a2a.grpc.SendMessageResponse.Builder builder = io.a2a.grpc.SendMessageResponse.newBuilder(); parseRequestBody(paramsNode, builder, id); - if (builder.hasMsg()) { - return new SendMessageResponse(id, ProtoUtils.FromProto.message(builder.getMsg())); + if (builder.hasMessage()) { + return new SendMessageResponse(id, ProtoUtils.FromProto.message(builder.getMessage())); } return new SendMessageResponse(id, ProtoUtils.FromProto.task(builder.getTask())); } @@ -330,7 +330,7 @@ public static A2AResponse parseResponseBody(String body, String method) throw case GET_EXTENDED_AGENT_CARD_METHOD -> { io.a2a.grpc.AgentCard.Builder builder = io.a2a.grpc.AgentCard.newBuilder(); parseRequestBody(paramsNode, builder, id); - return new GetAuthenticatedExtendedCardResponse(id, ProtoUtils.FromProto.agentCard(builder)); + return new GetExtendedAgentCardResponse(id, ProtoUtils.FromProto.agentCard(builder)); } default -> throw new MethodNotFoundJsonMappingException("Unsupported JSON-RPC method: '" + method + "' in response parsing.", getIdIfPossible(jsonRpc)); @@ -393,8 +393,8 @@ private static A2AError processError(JsonObject error) { return new ContentTypeNotSupportedError(code, message, data); case INVALID_AGENT_RESPONSE_ERROR_CODE: return new InvalidAgentResponseError(code, message, data); - case EXTENDED_CARD_NOT_CONFIGURED_ERROR_CODE: - return new ExtendedCardNotConfiguredError(code, message, data); + case EXTENDED_AGENT_CARD_NOT_CONFIGURED_ERROR_CODE: + return new ExtendedAgentCardNotConfiguredError(code, message, data); case EXTENSION_SUPPORT_REQUIRED_ERROR: return new ExtensionSupportRequiredError(code, message, data); case VERSION_NOT_SUPPORTED_ERROR_CODE: diff --git a/spec-grpc/src/main/java/io/a2a/grpc/utils/ProtoUtils.java b/spec-grpc/src/main/java/io/a2a/grpc/utils/ProtoUtils.java index b4e9a1755..b2941dc98 100644 --- a/spec-grpc/src/main/java/io/a2a/grpc/utils/ProtoUtils.java +++ b/spec-grpc/src/main/java/io/a2a/grpc/utils/ProtoUtils.java @@ -149,7 +149,7 @@ public static io.a2a.grpc.SendMessageResponse taskOrMessage(EventKind eventKind) .setTask(task((Task) eventKind)) .build(); case Message.STREAMING_EVENT_ID -> io.a2a.grpc.SendMessageResponse.newBuilder() - .setMsg(message((Message) eventKind)) + .setMessage(message((Message) eventKind)) .build(); default -> throw new IllegalArgumentException("Unsupported event type: " + eventKind); }; @@ -161,7 +161,7 @@ public static io.a2a.grpc.StreamResponse taskOrMessageStream(StreamingEventKind .setTask(task((Task) eventKind)) .build(); case Message.STREAMING_EVENT_ID -> io.a2a.grpc.StreamResponse.newBuilder() - .setMsg(message((Message) eventKind)) + .setMessage(message((Message) eventKind)) .build(); case TaskStatusUpdateEvent.STREAMING_EVENT_ID -> io.a2a.grpc.StreamResponse.newBuilder() .setStatusUpdate(taskStatusUpdateEvent((TaskStatusUpdateEvent) eventKind)) @@ -181,7 +181,7 @@ public static io.a2a.grpc.TaskPushNotificationConfig getTaskPushNotificationConf return taskPushNotificationConfig(config); } - public static io.a2a.grpc.AgentCard getAuthenticatedExtendedCardResponse(AgentCard card) { + public static io.a2a.grpc.AgentCard getExtendedCardResponse(AgentCard card) { return agentCard(card); } } diff --git a/spec-grpc/src/main/proto/a2a.proto b/spec-grpc/src/main/proto/a2a.proto index 888fd18b8..ccf37e6ab 100644 --- a/spec-grpc/src/main/proto/a2a.proto +++ b/spec-grpc/src/main/proto/a2a.proto @@ -9,8 +9,6 @@ import "google/protobuf/empty.proto"; import "google/protobuf/struct.proto"; import "google/protobuf/timestamp.proto"; -//From commit c196824396bb4af4c595f30e2c503a5ab1dbac4b - option csharp_namespace = "A2a.V1"; option go_package = "google.golang.org/a2a/v1"; option java_multiple_files = true; @@ -145,7 +143,10 @@ message SendMessageConfiguration { repeated string accepted_output_modes = 1; // Configuration for the agent to send push notifications for task updates. PushNotificationConfig push_notification_config = 2; - // The maximum number of messages to include in the history. + // The maximum number of most recent messages from the task's history to retrieve in + // the response. An unset value means the client does not impose any limit. A + // value of zero is a request to not include any messages. The server MUST NOT + // return more messages than the provided value, but MAY apply a lower limit. optional int32 history_length = 3; // If true, the operation waits until the task reaches a terminal state before returning. Default is false. bool blocking = 4; @@ -277,13 +278,12 @@ enum Role { // --8<-- [end:Role] // --8<-- [start:Message] -// Message is one unit of communication between client and server. It is -// associated with a context and optionally a task. Since the server is -// responsible for the context definition, it must always provide a context_id -// in its messages. The client can optionally provide the context_id if it -// knows the context to associate the message to. Similarly for task_id, -// except the server decides if a task is created and whether to include the -// task_id. +// Message is one unit of communication between client and server. It can be +// associated with a context and/or a task. For server messages, context_id must +// be provided, and task_id only if a task was created. For client messages, both +// fields are optional, with the caveat that if both are provided, they have to +// match (the context_id has to be the one that is set on the task). If only +// task_id is provided, the server will infer context_id from it. message Message { // The unique identifier (e.g. UUID) of the message. This is required and // created by the message creator. @@ -411,9 +411,14 @@ message AgentInterface { // communication methods, and security requirements. // Next ID: 20 message AgentCard { - // The version of the A2A protocol this agent supports. - // Default: "1.0" - optional string protocol_version = 16 [(google.api.field_behavior) = REQUIRED]; + // The versions of the A2A protocol this agent supports. + // For stable versions (1.x+), list only the latest supported minor version per major version. + // For legacy experimental versions (0.x), explicitly list each supported version. + // Default: ["1.0"] + repeated string protocol_versions = 16 [(google.api.field_behavior) = REQUIRED]; + // Reserve these field numbers as they were previously used by removed + // fields. + reserved 3, 14, 15; // A human readable name for the agent. // Example: "Recipe Agent" string name = 1 [(google.api.field_behavior) = REQUIRED]; @@ -422,13 +427,7 @@ message AgentCard { // Example: "Agent that helps users with recipes and cooking." string description = 2 [(google.api.field_behavior) = REQUIRED]; // Ordered list of supported interfaces. First entry is preferred. - repeated AgentInterface supported_interfaces = 19; - // DEPRECATED: Use 'supported_interfaces' instead. - optional string url = 3 [deprecated = true]; - // DEPRECATED: Use 'supported_interfaces' instead. - optional string preferred_transport = 14 [deprecated = true]; - // DEPRECATED: Use 'supported_interfaces' instead. - repeated AgentInterface additional_interfaces = 15 [deprecated = true]; + repeated AgentInterface supported_interfaces = 19 [(google.api.field_behavior) = REQUIRED]; // The service provider of the agent. AgentProvider provider = 4; // The version of the agent. @@ -453,8 +452,6 @@ message AgentCard { // a descriptive concept but represents a more focused set of behaviors that the // agent is likely to succeed at. repeated AgentSkill skills = 12 [(google.api.field_behavior) = REQUIRED]; - // Whether the agent supports providing an extended agent card when authenticated. - optional bool supports_extended_agent_card = 13; // JSON Web Signatures computed for this AgentCard. repeated AgentCardSignature signatures = 17; // An optional URL to an icon for the agent. @@ -485,6 +482,8 @@ message AgentCapabilities { repeated AgentExtension extensions = 3; // Indicates if the agent provides a history of state transitions for a task. optional bool state_transition_history = 4; + // Indicates if the agent supports providing an extended agent card when authenticated. + optional bool extended_agent_card = 5; } // --8<-- [end:AgentCapabilities] @@ -644,15 +643,15 @@ message MutualTlsSecurityScheme { // --8<-- [start:OAuthFlows] // Defines the configuration for the supported OAuth 2.0 flows. message OAuthFlows { + // Tags 3 and 4 were previously used by deprecated OAuth flows. + reserved 3, 4; oneof flow { // Configuration for the OAuth Authorization Code flow. AuthorizationCodeOAuthFlow authorization_code = 1; // Configuration for the OAuth Client Credentials flow. ClientCredentialsOAuthFlow client_credentials = 2; - // Configuration for the OAuth Implicit flow. - ImplicitOAuthFlow implicit = 3; - // Configuration for the OAuth Resource Owner Password flow. - PasswordOAuthFlow password = 4; + // Configuration for the OAuth Device Code flow. + DeviceCodeOAuthFlow device_code = 5; } } // --8<-- [end:OAuthFlows] @@ -668,6 +667,9 @@ message AuthorizationCodeOAuthFlow { string refresh_url = 3; // The available scopes for the OAuth2 security scheme. map scopes = 4 [(google.api.field_behavior) = REQUIRED]; + // Indicates if PKCE (RFC 7636) is required for this flow. + // PKCE should always be used for public clients and is recommended for all clients. + bool pkce_required = 5; } // --8<-- [end:AuthorizationCodeOAuthFlow] @@ -683,29 +685,21 @@ message ClientCredentialsOAuthFlow { } // --8<-- [end:ClientCredentialsOAuthFlow] -// --8<-- [start:ImplicitOAuthFlow] -// Defines configuration details for the OAuth 2.0 Implicit flow. -message ImplicitOAuthFlow { - // The authorization URL to be used for this flow. - string authorization_url = 1 [(google.api.field_behavior) = REQUIRED]; - // The URL to be used for obtaining refresh tokens. - string refresh_url = 2; - // The available scopes for the OAuth2 security scheme. - map scopes = 3 [(google.api.field_behavior) = REQUIRED]; -} -// --8<-- [end:ImplicitOAuthFlow] - -// --8<-- [start:PasswordOAuthFlow] -// Defines configuration details for the OAuth 2.0 Resource Owner Password flow. -message PasswordOAuthFlow { +// --8<-- [start:DeviceCodeOAuthFlow] +// Defines configuration details for the OAuth 2.0 Device Code flow (RFC 8628). +// This flow is designed for input-constrained devices such as IoT devices, +// and CLI tools where the user authenticates on a separate device. +message DeviceCodeOAuthFlow { + // The device authorization endpoint URL. + string device_authorization_url = 1 [(google.api.field_behavior) = REQUIRED]; // The token URL to be used for this flow. - string token_url = 1 [(google.api.field_behavior) = REQUIRED]; + string token_url = 2 [(google.api.field_behavior) = REQUIRED]; // The URL to be used for obtaining refresh tokens. - string refresh_url = 2; + string refresh_url = 3; // The available scopes for the OAuth2 security scheme. - map scopes = 3 [(google.api.field_behavior) = REQUIRED]; + map scopes = 4 [(google.api.field_behavior) = REQUIRED]; } -// --8<-- [end:PasswordOAuthFlow] +// --8<-- [end:DeviceCodeOAuthFlow] ///////////// Request Messages /////////// // --8<-- [start:SendMessageRequest] @@ -714,10 +708,7 @@ message SendMessageRequest { // Optional tenant, provided as a path parameter. string tenant = 4; // The message to send to the agent. - Message request = 1 [ - (google.api.field_behavior) = REQUIRED, - json_name = "message" - ]; + Message message = 1 [(google.api.field_behavior) = REQUIRED]; // Configuration for the send request. SendMessageConfiguration configuration = 2; // A flexible key-value map for passing additional context or parameters. @@ -733,7 +724,10 @@ message GetTaskRequest { // The resource name of the task. // Format: tasks/{task_id} string name = 1 [(google.api.field_behavior) = REQUIRED]; - // The maximum number of messages to include in the history. + // The maximum number of most recent messages from the task's history to retrieve. An + // unset value means the client does not impose any limit. A value of zero is + // a request to not include any messages. The server MUST NOT return more + // messages than the provided value, but MAY apply a lower limit. optional int32 history_length = 2; } // --8<-- [end:GetTaskRequest] @@ -754,9 +748,9 @@ message ListTasksRequest { string page_token = 4; // The maximum number of messages to include in each task's history. optional int32 history_length = 5; - // Filter tasks updated after this timestamp (milliseconds since epoch). - // Only tasks with a last updated time greater than or equal to this value will be returned. - int64 last_updated_after = 6; + // Filter tasks which have a status updated after the provided timestamp in ISO 8601 format (e.g., "2023-10-27T10:00:00Z"). + // Only tasks with a status timestamp time greater than or equal to this value will be returned. + google.protobuf.Timestamp status_timestamp_after = 6; // Whether to include artifacts in the returned tasks. // Defaults to false to reduce payload size. optional bool include_artifacts = 7; @@ -861,7 +855,7 @@ message GetExtendedAgentCardRequest { message SendMessageResponse { oneof payload { Task task = 1; - Message msg = 2 [json_name = "message"]; + Message message = 2; } } // --8<-- [end:SendMessageResponse] @@ -873,7 +867,7 @@ message StreamResponse { // A Task object containing the current state of the task. Task task = 1; // A Message object containing a message from the agent. - Message msg = 2 [json_name = "message"]; + Message message = 2; // An event indicating a task status update. TaskStatusUpdateEvent status_update = 3; // An event indicating a task artifact update. @@ -892,4 +886,4 @@ message ListTaskPushNotificationConfigResponse { // If this field is omitted, there are no subsequent pages. string next_page_token = 2; } -// --8<-- [end:ListTaskPushNotificationConfigResponse] +// --8<-- [end:ListTaskPushNotificationConfigResponse] \ No newline at end of file diff --git a/spec-grpc/src/test/java/io/a2a/grpc/mapper/StreamResponseMapperTest.java b/spec-grpc/src/test/java/io/a2a/grpc/mapper/StreamResponseMapperTest.java index 0619af352..bd007d61f 100644 --- a/spec-grpc/src/test/java/io/a2a/grpc/mapper/StreamResponseMapperTest.java +++ b/spec-grpc/src/test/java/io/a2a/grpc/mapper/StreamResponseMapperTest.java @@ -80,17 +80,17 @@ void testConvertMessage_ToProto() { // Assert assertNotNull(result); - assertEquals(io.a2a.grpc.StreamResponse.PayloadCase.MSG, result.getPayloadCase()); - assertEquals("msg-123", result.getMsg().getMessageId()); - assertEquals("context-456", result.getMsg().getContextId()); - assertEquals(io.a2a.grpc.Role.ROLE_USER, result.getMsg().getRole()); + assertEquals(io.a2a.grpc.StreamResponse.PayloadCase.MESSAGE, result.getPayloadCase()); + assertEquals("msg-123", result.getMessage().getMessageId()); + assertEquals("context-456", result.getMessage().getContextId()); + assertEquals(io.a2a.grpc.Role.ROLE_USER, result.getMessage().getRole()); } @Test void testConvertMessage_FromProto() { // Arrange io.a2a.grpc.StreamResponse proto = io.a2a.grpc.StreamResponse.newBuilder() - .setMsg(io.a2a.grpc.Message.newBuilder() + .setMessage(io.a2a.grpc.Message.newBuilder() .setMessageId("msg-123") .setContextId("context-456") .setRole(io.a2a.grpc.Role.ROLE_USER) diff --git a/spec-grpc/src/test/java/io/a2a/grpc/utils/ToProtoTest.java b/spec-grpc/src/test/java/io/a2a/grpc/utils/ToProtoTest.java index ec6d1cd86..e0a67c9c8 100644 --- a/spec-grpc/src/test/java/io/a2a/grpc/utils/ToProtoTest.java +++ b/spec-grpc/src/test/java/io/a2a/grpc/utils/ToProtoTest.java @@ -6,6 +6,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertNotNull; +import static org.junit.jupiter.api.Assertions.assertTrue; import java.time.OffsetDateTime; import java.util.Collections; @@ -65,7 +66,7 @@ public void convertAgentCard() { .tags(Collections.singletonList("hello world")) .examples(List.of("hi", "hello world")) .build())) - .protocolVersion("123") // Weird protool version on purpose to make sure non-default takes effect + .protocolVersions("123") // Weird protool version on purpose to make sure non-default takes effect .build(); io.a2a.grpc.AgentCard result = ProtoUtils.ToProto.agentCard(agentCard); assertEquals("Hello World Agent", result.getName()); @@ -79,7 +80,8 @@ public void convertAgentCard() { assertEquals("text", result.getDefaultInputModes(0)); assertEquals(1, result.getDefaultOutputModesCount()); assertEquals("text", result.getDefaultOutputModes(0)); - assertEquals("123", result.getProtocolVersion()); + // protocolVersions is now a repeated field, checking if the list contains the value + assertTrue(result.getProtocolVersionsList().contains("123")); agentCard = AgentCard.builder() .name("Hello World Agent") .description("Just a hello world agent") @@ -103,7 +105,7 @@ public void convertAgentCard() { // .iconUrl("http://example.com/icon.svg") .securitySchemes(Map.of("basic", HTTPAuthSecurityScheme.builder().scheme("basic").description("Basic Auth").build())) .security(List.of(Map.of("oauth", List.of("read")))) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); result = ProtoUtils.ToProto.agentCard(agentCard); assertEquals("Hello World Agent", result.getName()); @@ -117,7 +119,8 @@ public void convertAgentCard() { assertEquals("text", result.getDefaultInputModes(0)); assertEquals(1, result.getDefaultOutputModesCount()); assertEquals("text", result.getDefaultOutputModes(0)); - assertEquals(CURRENT_PROTOCOL_VERSION, result.getProtocolVersion()); + // protocolVersions is now a repeated field, checking if the list contains the value + assertTrue(result.getProtocolVersionsList().contains(CURRENT_PROTOCOL_VERSION)); assertEquals(1, result.getSecurityCount()); assertEquals(1, result.getSecurity(0).getSchemesMap().size()); assertEquals(true, result.getSecurity(0).getSchemesMap().containsKey("oauth")); diff --git a/spec/src/main/java/io/a2a/spec/A2AErrorCodes.java b/spec/src/main/java/io/a2a/spec/A2AErrorCodes.java index 9c1b4c88a..8eb4c6584 100644 --- a/spec/src/main/java/io/a2a/spec/A2AErrorCodes.java +++ b/spec/src/main/java/io/a2a/spec/A2AErrorCodes.java @@ -23,8 +23,8 @@ public interface A2AErrorCodes { /** Error code indicating the agent returned an invalid response (-32006). */ int INVALID_AGENT_RESPONSE_ERROR_CODE = -32006; - /** Error code indicating extended card is not configured (-32007). */ - int EXTENDED_CARD_NOT_CONFIGURED_ERROR_CODE = -32007; + /** Error code indicating extended agent card is not configured (-32007). */ + int EXTENDED_AGENT_CARD_NOT_CONFIGURED_ERROR_CODE = -32007; /** Error code indicating client requested use of an extension marked as required: true in the Agent Card * but the client did not declare support for it in the request (-32008). */ diff --git a/spec/src/main/java/io/a2a/spec/AgentCapabilities.java b/spec/src/main/java/io/a2a/spec/AgentCapabilities.java index 2913a2b97..ae8fb6f01 100644 --- a/spec/src/main/java/io/a2a/spec/AgentCapabilities.java +++ b/spec/src/main/java/io/a2a/spec/AgentCapabilities.java @@ -26,12 +26,16 @@ * @param streaming whether the agent supports streaming responses with incremental artifacts * @param pushNotifications whether the agent supports push notifications for state changes * @param stateTransitionHistory whether the agent maintains state transition history + * @param extendedAgentCard whether the agent supports an extended agent card * @param extensions list of custom extensions supported by the agent (optional) * @see AgentCard * @see AgentExtension * @see A2A Protocol Specification */ -public record AgentCapabilities(boolean streaming, boolean pushNotifications, boolean stateTransitionHistory, +public record AgentCapabilities(boolean streaming, + boolean pushNotifications, + boolean stateTransitionHistory, + boolean extendedAgentCard, List extensions) { /** @@ -62,6 +66,7 @@ public static class Builder { private boolean streaming; private boolean pushNotifications; private boolean stateTransitionHistory; + private boolean extendedAgentCard; private List extensions; /** @@ -112,6 +117,18 @@ public Builder stateTransitionHistory(boolean stateTransitionHistory) { return this; } + /** + * Sets whether the agent supports an extended agent card. + * state transition history. + * + * @param extendedAgentCard true if an extended agent card is supported, false otherwise + * @return this builder for method chaining + */ + public Builder extendedAgentCard(boolean extendedAgentCard) { + this.extendedAgentCard = extendedAgentCard; + return this; + } + /** * Sets the list of custom extensions supported by the agent. *

    @@ -133,7 +150,7 @@ public Builder extensions(List extensions) { * @return a new AgentCapabilities instance */ public AgentCapabilities build() { - return new AgentCapabilities(streaming, pushNotifications, stateTransitionHistory, extensions); + return new AgentCapabilities(streaming, pushNotifications, stateTransitionHistory, extendedAgentCard, extensions); } } } diff --git a/spec/src/main/java/io/a2a/spec/AgentCard.java b/spec/src/main/java/io/a2a/spec/AgentCard.java index d8ed1231a..f5a642509 100644 --- a/spec/src/main/java/io/a2a/spec/AgentCard.java +++ b/spec/src/main/java/io/a2a/spec/AgentCard.java @@ -32,12 +32,11 @@ * @param defaultInputModes list of supported input modes, e.g., "text", "audio" (required) * @param defaultOutputModes list of supported output modes, e.g., "text", "audio" (required) * @param skills list of skills that this agent can perform (required) - * @param supportsExtendedAgentCard whether the agent supports authenticated extended card retrieval (optional, defaults to false) * @param securitySchemes map of security scheme names to their definitions (optional) * @param security list of security requirements for accessing the agent (optional) * @param iconUrl URL to an icon representing the agent (optional) * @param supportedInterfaces ordered list of protocol+URL interface combinations; first entry is preferred (required) - * @param protocolVersion the version of the A2A Protocol this agent implements (defaults to {@link #CURRENT_PROTOCOL_VERSION}) + * @param protocolVersions the versions of the A2A Protocol this agent implements (defaults to a singleton list of {@link #CURRENT_PROTOCOL_VERSION}) * @param signatures digital signatures verifying the authenticity of the agent card (optional) * @see AgentInterface * @see A2A Protocol Specification @@ -52,12 +51,11 @@ public record AgentCard( List defaultInputModes, List defaultOutputModes, List skills, - boolean supportsExtendedAgentCard, Map securitySchemes, List>> security, String iconUrl, List supportedInterfaces, - String protocolVersion, + List protocolVersions, List signatures) { /** The default A2A Protocol version used when not explicitly specified. */ @@ -75,12 +73,11 @@ public record AgentCard( * @param defaultInputModes the defaultInputModes parameter (see class-level JavaDoc) * @param defaultOutputModes the defaultOutputModes parameter (see class-level JavaDoc) * @param skills the skills parameter (see class-level JavaDoc) - * @param supportsExtendedAgentCard the supportsExtendedAgentCard parameter (see class-level JavaDoc) * @param securitySchemes the securitySchemes parameter (see class-level JavaDoc) * @param security the security parameter (see class-level JavaDoc) * @param iconUrl the iconUrl parameter (see class-level JavaDoc) * @param supportedInterfaces the supportedInterfaces parameter (see class-level JavaDoc) - * @param protocolVersion the protocolVersion parameter (see class-level JavaDoc) + * @param protocolVersions the protocolVersions parameter (see class-level JavaDoc) * @param signatures the signatures parameter (see class-level JavaDoc) * @throws IllegalArgumentException if any required field is null */ @@ -94,8 +91,8 @@ public record AgentCard( Assert.checkNotNullParam("supportedInterfaces", supportedInterfaces); Assert.checkNotNullParam("version", version); - if (protocolVersion == null) { - protocolVersion = CURRENT_PROTOCOL_VERSION; + if (protocolVersions == null || protocolVersions.isEmpty()) { + protocolVersions = List.of(CURRENT_PROTOCOL_VERSION); } } @@ -162,12 +159,11 @@ public static class Builder { private List defaultInputModes; private List defaultOutputModes; private List skills; - private boolean supportsExtendedAgentCard = false; private Map securitySchemes; private List>> security; private String iconUrl; private List supportedInterfaces; - private String protocolVersion; + private List protocolVersions; private List signatures; /** @@ -195,12 +191,11 @@ private Builder(AgentCard card) { this.defaultInputModes = card.defaultInputModes != null ? new ArrayList<>(card.defaultInputModes) : null; this.defaultOutputModes = card.defaultOutputModes != null ? new ArrayList<>(card.defaultOutputModes) : null; this.skills = card.skills != null ? new ArrayList<>(card.skills) : null; - this.supportsExtendedAgentCard = card.supportsExtendedAgentCard; this.securitySchemes = card.securitySchemes != null ? Map.copyOf(card.securitySchemes) : null; this.security = card.security != null ? new ArrayList<>(card.security) : null; this.iconUrl = card.iconUrl; this.supportedInterfaces = card.supportedInterfaces != null ? new ArrayList<>(card.supportedInterfaces) : null; - this.protocolVersion = card.protocolVersion; + this.protocolVersions = card.protocolVersions; this.signatures = card.signatures != null ? new ArrayList<>(card.signatures) : null; } @@ -316,21 +311,6 @@ public Builder skills(List skills) { return this; } - /** - * Sets whether the agent supports extended card retrieval. - *

    - * When true, the agent can provide additional information through the - * {@code GetAuthenticatedExtendedCard} method, which may include private - * or user-specific details not in the public card. - * - * @param supportsExtendedAgentCard true if supported, false otherwise - * @return this builder for method chaining - */ - public Builder supportsExtendedAgentCard(boolean supportsExtendedAgentCard) { - this.supportsExtendedAgentCard = supportsExtendedAgentCard; - return this; - } - /** * Sets the map of security scheme definitions. *

    @@ -398,13 +378,13 @@ public Builder supportedInterfaces(List supportedInterfaces) { /** * Sets the version of the A2A Protocol this agent implements. *

    - * If not set, defaults to {@link AgentCard#CURRENT_PROTOCOL_VERSION}. + * If not set, defaults to a single list of {@link AgentCard#CURRENT_PROTOCOL_VERSION}. * - * @param protocolVersion the protocol version string + * @param protocolVersions the protocol versions * @return this builder for method chaining */ - public Builder protocolVersion(String protocolVersion) { - this.protocolVersion = protocolVersion; + public Builder protocolVersions(String... protocolVersions) { + this.protocolVersions = List.of(protocolVersions); return this; } @@ -434,8 +414,8 @@ public Builder signatures(List signatures) { public AgentCard build() { return new AgentCard(name, description, provider, version, documentationUrl, capabilities, defaultInputModes, defaultOutputModes, skills, - supportsExtendedAgentCard, securitySchemes, security, iconUrl, - supportedInterfaces, protocolVersion, signatures); + securitySchemes, security, iconUrl, + supportedInterfaces, protocolVersions, signatures); } } } diff --git a/spec/src/main/java/io/a2a/spec/AuthorizationCodeOAuthFlow.java b/spec/src/main/java/io/a2a/spec/AuthorizationCodeOAuthFlow.java index c4db756a4..d3d399057 100644 --- a/spec/src/main/java/io/a2a/spec/AuthorizationCodeOAuthFlow.java +++ b/spec/src/main/java/io/a2a/spec/AuthorizationCodeOAuthFlow.java @@ -19,13 +19,14 @@ * @param refreshUrl URL for obtaining refresh tokens (optional) * @param scopes map of available OAuth scopes to their descriptions (required) * @param tokenUrl URL for the token endpoint where codes are exchanged for tokens (required) + * @param pkceRequired Indicates if PKCE (RFC 7636) is required for this flow. (required) * @see OAuthFlows for the container of all supported OAuth flows * @see OAuth2SecurityScheme for the security scheme using these flows * @see RFC 6749 - Authorization Code Grant * @see A2A Protocol Specification */ public record AuthorizationCodeOAuthFlow(String authorizationUrl, String refreshUrl, Map scopes, - String tokenUrl) { + String tokenUrl, boolean pkceRequired) { /** * Compact constructor that validates required fields. @@ -34,6 +35,7 @@ public record AuthorizationCodeOAuthFlow(String authorizationUrl, String refresh * @param refreshUrl the refreshUrl parameter (see class-level JavaDoc) * @param scopes the scopes parameter (see class-level JavaDoc) * @param tokenUrl the tokenUrl parameter (see class-level JavaDoc) + * @param pkceRequired Indicates if PKCE (RFC 7636) is required for this flow. (required) * @throws IllegalArgumentException if authorizationUrl, scopes, or tokenUrl is null */ public AuthorizationCodeOAuthFlow { diff --git a/spec/src/main/java/io/a2a/spec/DeviceCodeOAuthFlow.java b/spec/src/main/java/io/a2a/spec/DeviceCodeOAuthFlow.java new file mode 100644 index 000000000..d2d25c047 --- /dev/null +++ b/spec/src/main/java/io/a2a/spec/DeviceCodeOAuthFlow.java @@ -0,0 +1,37 @@ +package io.a2a.spec; + +import java.util.Map; + +import io.a2a.util.Assert; + +/** + * Configuration details for the OAuth 2.0 Device Code flow (RFC 8628). + *

    + * This flow is designed for input-constrained devices such as IoT devices, + * and CLI tools where the user authenticates on a separate device. + * + * @param deviceAuthorizationUrl the device authorization endpoint URL (required) + * @param tokenUrl URL for the token endpoint where credentials are exchanged for tokens (required) + * @param refreshUrl URL for obtaining refresh tokens (optional) + * @param scopes map of available OAuth scopes to their descriptions (required) + * @see OAuthFlows for the container of all supported OAuth flows + * @see OAuth2SecurityScheme for the security scheme using these flows + * @see A2A Protocol Specification + */ +public record DeviceCodeOAuthFlow(String deviceAuthorizationUrl, String tokenUrl, String refreshUrl, Map scopes) { + + /** + * Compact constructor that validates required fields. + * + * @param deviceAuthorizationUrl the device authorization endpoint URL (required) + * @param tokenUrl URL for the token endpoint where credentials are exchanged for tokens (required) + * @param refreshUrl URL for obtaining refresh tokens (optional) + * @param scopes map of available OAuth scopes to their descriptions (required) + * @throws IllegalArgumentException if authorizationUrl, scopes, or tokenUrl is null + */ + public DeviceCodeOAuthFlow { + Assert.checkNotNullParam("deviceAuthorizationUrl", deviceAuthorizationUrl); + Assert.checkNotNullParam("tokenUrl", tokenUrl); + Assert.checkNotNullParam("scopes", scopes); + } +} diff --git a/spec/src/main/java/io/a2a/spec/ExtendedCardNotConfiguredError.java b/spec/src/main/java/io/a2a/spec/ExtendedAgentCardNotConfiguredError.java similarity index 78% rename from spec/src/main/java/io/a2a/spec/ExtendedCardNotConfiguredError.java rename to spec/src/main/java/io/a2a/spec/ExtendedAgentCardNotConfiguredError.java index 3403b3ffd..c8998fe04 100644 --- a/spec/src/main/java/io/a2a/spec/ExtendedCardNotConfiguredError.java +++ b/spec/src/main/java/io/a2a/spec/ExtendedAgentCardNotConfiguredError.java @@ -1,6 +1,6 @@ package io.a2a.spec; -import static io.a2a.spec.A2AErrorCodes.EXTENDED_CARD_NOT_CONFIGURED_ERROR_CODE; +import static io.a2a.spec.A2AErrorCodes.EXTENDED_AGENT_CARD_NOT_CONFIGURED_ERROR_CODE; import static io.a2a.util.Utils.defaultIfNull; @@ -19,15 +19,15 @@ * Usage example: *

    {@code
      * // In agent implementation
    - * if (authenticatedExtendedCard == null) {
    - *     throw new AuthenticatedExtendedCardNotConfiguredError();
    + * if (extendedAgentCard == null) {
    + *     throw new ExtendedAgentCardNotConfiguredError();
      * }
      * }
    * * @see AgentCard for the base agent card structure * @see A2A Protocol Specification */ -public class ExtendedCardNotConfiguredError extends A2AProtocolError { +public class ExtendedAgentCardNotConfiguredError extends A2AProtocolError { /** * Constructs an error for agents that don't support authenticated extended card retrieval. @@ -36,12 +36,12 @@ public class ExtendedCardNotConfiguredError extends A2AProtocolError { * @param message the error message * @param data additional error data */ - public ExtendedCardNotConfiguredError( + public ExtendedAgentCardNotConfiguredError( Integer code, String message, Object data) { super( - defaultIfNull(code, EXTENDED_CARD_NOT_CONFIGURED_ERROR_CODE), + defaultIfNull(code, EXTENDED_AGENT_CARD_NOT_CONFIGURED_ERROR_CODE), defaultIfNull(message, "Extended Card not configured"), data, "https://a2a-protocol.org/errors/extended-agent-card-not-configured"); diff --git a/spec/src/main/java/io/a2a/spec/ImplicitOAuthFlow.java b/spec/src/main/java/io/a2a/spec/ImplicitOAuthFlow.java deleted file mode 100644 index 06341ab2b..000000000 --- a/spec/src/main/java/io/a2a/spec/ImplicitOAuthFlow.java +++ /dev/null @@ -1,40 +0,0 @@ -package io.a2a.spec; - -import java.util.Map; - -import io.a2a.util.Assert; - -/** - * Configuration for the OAuth 2.0 Implicit flow. - *

    - * The implicit flow is designed for browser-based applications where the client - * cannot securely store credentials. The access token is returned directly from - * the authorization endpoint without an intermediate authorization code. - *

    - * Note: The implicit flow is considered less secure than the - * authorization code flow and is deprecated in OAuth 2.1. It should only be used - * for legacy applications or when the authorization code flow with PKCE is not feasible. - * - * @param authorizationUrl URL for the authorization endpoint where users authenticate (required) - * @param refreshUrl URL for obtaining refresh tokens (optional, rarely used in implicit flow) - * @param scopes map of available OAuth scopes to their descriptions (required) - * @see OAuthFlows for the container of all supported OAuth flows - * @see OAuth2SecurityScheme for the security scheme using these flows - * @see RFC 6749 - Implicit Grant - * @see A2A Protocol Specification - */ -public record ImplicitOAuthFlow(String authorizationUrl, String refreshUrl, Map scopes) { - - /** - * Compact constructor that validates required fields. - * - * @param authorizationUrl the authorizationUrl parameter (see class-level JavaDoc) - * @param refreshUrl the refreshUrl parameter (see class-level JavaDoc) - * @param scopes the scopes parameter (see class-level JavaDoc) - * @throws IllegalArgumentException if authorizationUrl or scopes is null - */ - public ImplicitOAuthFlow { - Assert.checkNotNullParam("authorizationUrl", authorizationUrl); - Assert.checkNotNullParam("scopes", scopes); - } -} diff --git a/spec/src/main/java/io/a2a/spec/ListTasksParams.java b/spec/src/main/java/io/a2a/spec/ListTasksParams.java index 6fb9ff5d1..d99d25bcf 100644 --- a/spec/src/main/java/io/a2a/spec/ListTasksParams.java +++ b/spec/src/main/java/io/a2a/spec/ListTasksParams.java @@ -12,7 +12,7 @@ * @param pageSize Maximum number of tasks to return (1-100, defaults to 50) * @param pageToken Token for pagination from a previous ListTasksResult * @param historyLength Number of recent messages to include in each task's history (defaults to 0) - * @param lastUpdatedAfter Filter tasks updated after this timestamp + * @param statusTimestampAfter Filter tasks updated after this timestamp * @param includeArtifacts Whether to include artifacts in the returned tasks (defaults to false) * @param tenant optional tenant, provided as a path parameter. */ @@ -22,7 +22,7 @@ public record ListTasksParams( @Nullable Integer pageSize, @Nullable String pageToken, @Nullable Integer historyLength, - @Nullable Instant lastUpdatedAfter, + @Nullable Instant statusTimestampAfter, @Nullable Boolean includeArtifacts, String tenant ) { @@ -38,7 +38,7 @@ public record ListTasksParams( * @param pageSize maximum number of results per page * @param pageToken pagination token * @param historyLength number of history items to include - * @param lastUpdatedAfter filter by last update timestamp + * @param statusTimestampAfter filter by status timestamp * @param includeArtifacts whether to include artifacts * @param tenant the tenant identifier * @throws InvalidParamsError if tenant is null or if pageSize or historyLength are out of valid range @@ -124,7 +124,7 @@ public static class Builder { private Integer pageSize; private String pageToken; private Integer historyLength; - private Instant lastUpdatedAfter; + private Instant statusTimestampAfter; private Boolean includeArtifacts; private String tenant; @@ -190,13 +190,13 @@ public Builder historyLength(Integer historyLength) { } /** - * Sets the lastUpdatedAfter. + * Sets the statusTimestampAfter. * - * @param lastUpdatedAfter the lastUpdatedAfter + * @param statusTimestampAfter the statusTimestampAfter * @return this builder for method chaining */ - public Builder lastUpdatedAfter(Instant lastUpdatedAfter) { - this.lastUpdatedAfter = lastUpdatedAfter; + public Builder statusTimestampAfter(Instant statusTimestampAfter) { + this.statusTimestampAfter = statusTimestampAfter; return this; } @@ -229,7 +229,7 @@ public Builder tenant(String tenant) { */ public ListTasksParams build() { return new ListTasksParams(contextId, status, pageSize, pageToken, historyLength, - lastUpdatedAfter, includeArtifacts, tenant); + statusTimestampAfter, includeArtifacts, tenant); } } } diff --git a/spec/src/main/java/io/a2a/spec/OAuthFlows.java b/spec/src/main/java/io/a2a/spec/OAuthFlows.java index bcddf7f43..5cabfcccd 100644 --- a/spec/src/main/java/io/a2a/spec/OAuthFlows.java +++ b/spec/src/main/java/io/a2a/spec/OAuthFlows.java @@ -10,14 +10,13 @@ * * @param authorizationCode OAuth 2.0 authorization code flow configuration * @param clientCredentials OAuth 2.0 client credentials flow configuration - * @param implicit OAuth 2.0 implicit flow configuration - * @param password OAuth 2.0 resource owner password credentials flow configuration + * @param deviceCode OAuth 2.0 device code flow configuration * @see OAuth2SecurityScheme for the security scheme using these flows * @see OpenAPI OAuth Flows Object * @see A2A Protocol Specification */ public record OAuthFlows(AuthorizationCodeOAuthFlow authorizationCode, ClientCredentialsOAuthFlow clientCredentials, - ImplicitOAuthFlow implicit, PasswordOAuthFlow password) { + DeviceCodeOAuthFlow deviceCode) { /** * Create a new Builder @@ -34,8 +33,7 @@ public static Builder builder() { public static class Builder { private AuthorizationCodeOAuthFlow authorizationCode; private ClientCredentialsOAuthFlow clientCredentials; - private ImplicitOAuthFlow implicit; - private PasswordOAuthFlow password; + private DeviceCodeOAuthFlow deviceCode; /** * Creates a new Builder with all fields unset. @@ -66,26 +64,16 @@ public Builder clientCredentials(ClientCredentialsOAuthFlow clientCredentials) { } /** - * Sets the implicit flow configuration. + * Sets the device code flow configuration. * - * @param implicit the implicit flow (optional) + * @param deviceCode the device code flow (optional) * @return this builder for method chaining */ - public Builder implicit(ImplicitOAuthFlow implicit) { - this.implicit = implicit; + public Builder deviceCode(DeviceCodeOAuthFlow deviceCode) { + this.deviceCode = deviceCode; return this; } - /** - * Sets the password flow configuration. - * - * @param password the password flow (optional) - * @return this builder for method chaining - */ - public Builder password(PasswordOAuthFlow password) { - this.password = password; - return this; - } /** * Builds a new immutable OAuthFlows instance. @@ -93,7 +81,7 @@ public Builder password(PasswordOAuthFlow password) { * @return a new OAuthFlows instance */ public OAuthFlows build() { - return new OAuthFlows(authorizationCode, clientCredentials, implicit, password); + return new OAuthFlows(authorizationCode, clientCredentials, deviceCode); } } } diff --git a/spec/src/main/java/io/a2a/spec/PasswordOAuthFlow.java b/spec/src/main/java/io/a2a/spec/PasswordOAuthFlow.java deleted file mode 100644 index a6a3a8803..000000000 --- a/spec/src/main/java/io/a2a/spec/PasswordOAuthFlow.java +++ /dev/null @@ -1,40 +0,0 @@ -package io.a2a.spec; - -import java.util.Map; - -import io.a2a.util.Assert; - -/** - * Configuration for the OAuth 2.0 Resource Owner Password Credentials flow. - *

    - * The password flow allows the client to exchange a user's credentials (username and password) - * directly for an access token. This flow should only be used when there is a high degree of - * trust between the user and the client application. - *

    - * Note: This flow is generally discouraged and deprecated in OAuth 2.1 - * because it exposes user credentials to the client. Use the authorization code flow - * with PKCE instead whenever possible. - * - * @param refreshUrl URL for obtaining refresh tokens (optional) - * @param scopes map of available OAuth scopes to their descriptions (required) - * @param tokenUrl URL for the token endpoint where credentials are exchanged for tokens (required) - * @see OAuthFlows for the container of all supported OAuth flows - * @see OAuth2SecurityScheme for the security scheme using these flows - * @see RFC 6749 - Resource Owner Password Credentials Grant - * @see A2A Protocol Specification - */ -public record PasswordOAuthFlow(String refreshUrl, Map scopes, String tokenUrl) { - - /** - * Compact constructor that validates required fields. - * - * @param refreshUrl the refreshUrl parameter (see class-level JavaDoc) - * @param scopes the scopes parameter (see class-level JavaDoc) - * @param tokenUrl the tokenUrl parameter (see class-level JavaDoc) - * @throws IllegalArgumentException if scopes or tokenUrl is null - */ - public PasswordOAuthFlow { - Assert.checkNotNullParam("scopes", scopes); - Assert.checkNotNullParam("tokenUrl", tokenUrl); - } -} diff --git a/spec/src/main/java/io/a2a/spec/VersionNotSupportedError.java b/spec/src/main/java/io/a2a/spec/VersionNotSupportedError.java index 50c8f3a45..955709986 100644 --- a/spec/src/main/java/io/a2a/spec/VersionNotSupportedError.java +++ b/spec/src/main/java/io/a2a/spec/VersionNotSupportedError.java @@ -23,7 +23,7 @@ * } * }

    * - * @see AgentCard#protocolVersion() for supported version declaration + * @see AgentCard#protocolVersions() for supported version declaration * @see A2A Protocol Specification */ public class VersionNotSupportedError extends A2AProtocolError { diff --git a/tck/src/main/java/io/a2a/tck/server/AgentCardProducer.java b/tck/src/main/java/io/a2a/tck/server/AgentCardProducer.java index d5b5d6ffd..526b81ce5 100644 --- a/tck/src/main/java/io/a2a/tck/server/AgentCardProducer.java +++ b/tck/src/main/java/io/a2a/tck/server/AgentCardProducer.java @@ -50,7 +50,7 @@ public AgentCard agentCard() { .tags(Collections.singletonList("hello world")) .examples(List.of("hi", "hello world")) .build())) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); } diff --git a/tests/server-common/src/test/java/io/a2a/server/apps/common/AbstractA2AServerTest.java b/tests/server-common/src/test/java/io/a2a/server/apps/common/AbstractA2AServerTest.java index 5fab9d8d7..d8a871e04 100644 --- a/tests/server-common/src/test/java/io/a2a/server/apps/common/AbstractA2AServerTest.java +++ b/tests/server-common/src/test/java/io/a2a/server/apps/common/AbstractA2AServerTest.java @@ -19,6 +19,7 @@ import java.net.http.HttpResponse; import java.nio.charset.StandardCharsets; import java.util.List; +import java.util.Optional; import java.util.concurrent.CompletableFuture; import java.util.concurrent.CopyOnWriteArrayList; import java.util.concurrent.CountDownLatch; @@ -606,21 +607,26 @@ public void testError() throws A2AClientException { } @Test - public void testGetAgentCard() throws A2AClientException { - AgentCard agentCard = getClient().getAgentCard(); + public void testGetExtendedAgentCard() throws A2AClientException { + AgentCard agentCard = getClient().getExtendedAgentCard(); assertNotNull(agentCard); assertEquals("test-card", agentCard.name()); assertEquals("A test agent card", agentCard.description()); assertNotNull(agentCard.supportedInterfaces()); assertFalse(agentCard.supportedInterfaces().isEmpty()); - assertEquals(getTransportUrl(), Utils.getFavoriteInterface(agentCard).url()); + Optional transportInterface = agentCard.supportedInterfaces().stream() + .filter(i -> getTransportProtocol().equals(i.protocolBinding())) + .findFirst(); + assertTrue(transportInterface.isPresent()); + System.out.println("transportInterface = " + transportInterface); + assertEquals(getTransportUrl(),transportInterface.get().url()); assertEquals("1.0", agentCard.version()); assertEquals("http://example.com/docs", agentCard.documentationUrl()); assertTrue(agentCard.capabilities().pushNotifications()); assertTrue(agentCard.capabilities().streaming()); assertTrue(agentCard.capabilities().stateTransitionHistory()); + assertTrue(agentCard.capabilities().extendedAgentCard()); assertTrue(agentCard.skills().isEmpty()); - assertFalse(agentCard.supportsExtendedAgentCard()); } @Test @@ -1994,7 +2000,7 @@ private AgentCard createTestAgentCard() { .defaultOutputModes(List.of("text")) .skills(List.of()) .supportedInterfaces(List.of(new AgentInterface(getTransportProtocol(), getTransportUrl()))) - .protocolVersion(CURRENT_PROTOCOL_VERSION) + .protocolVersions(CURRENT_PROTOCOL_VERSION) .build(); } diff --git a/tests/server-common/src/test/java/io/a2a/server/apps/common/AgentCardProducer.java b/tests/server-common/src/test/java/io/a2a/server/apps/common/AgentCardProducer.java index b8b9b376f..03ec3481b 100644 --- a/tests/server-common/src/test/java/io/a2a/server/apps/common/AgentCardProducer.java +++ b/tests/server-common/src/test/java/io/a2a/server/apps/common/AgentCardProducer.java @@ -1,6 +1,7 @@ package io.a2a.server.apps.common; import static io.a2a.spec.AgentCard.CURRENT_PROTOCOL_VERSION; +import static io.a2a.spec.TransportProtocol.GRPC; import java.io.IOException; import java.io.InputStream; @@ -12,10 +13,13 @@ import jakarta.enterprise.context.ApplicationScoped; import jakarta.enterprise.inject.Produces; +import io.a2a.server.ExtendedAgentCard; import io.a2a.server.PublicAgentCard; import io.a2a.spec.AgentCapabilities; import io.a2a.spec.AgentCard; import io.a2a.spec.AgentInterface; +import io.a2a.spec.TransportProtocol; + import io.quarkus.arc.profile.IfBuildProfile; import org.junit.jupiter.api.Assertions; @@ -28,9 +32,11 @@ public class AgentCardProducer { @Produces @PublicAgentCard + @ExtendedAgentCard public AgentCard agentCard() { String port = System.getProperty("test.agent.card.port", "8081"); String preferredTransport = loadPreferredTransportFromProperties(); + String transportUrl = GRPC.toString().equals(preferredTransport) ? "localhost:" + port : "http://localhost:" + port; AgentCard.Builder builder = AgentCard.builder() .name("test-card") @@ -41,12 +47,13 @@ public AgentCard agentCard() { .streaming(true) .pushNotifications(true) .stateTransitionHistory(true) + .extendedAgentCard(true) .build()) .defaultInputModes(Collections.singletonList("text")) .defaultOutputModes(Collections.singletonList("text")) .skills(new ArrayList<>()) - .protocolVersion(CURRENT_PROTOCOL_VERSION) - .supportedInterfaces(Collections.singletonList(new AgentInterface(preferredTransport, "http://localhost:" + port))); + .protocolVersions(CURRENT_PROTOCOL_VERSION) + .supportedInterfaces(Collections.singletonList(new AgentInterface(preferredTransport, transportUrl))); return builder.build(); } diff --git a/transport/grpc/src/main/java/io/a2a/transport/grpc/handler/GrpcHandler.java b/transport/grpc/src/main/java/io/a2a/transport/grpc/handler/GrpcHandler.java index 2998965ea..408205aa2 100644 --- a/transport/grpc/src/main/java/io/a2a/transport/grpc/handler/GrpcHandler.java +++ b/transport/grpc/src/main/java/io/a2a/transport/grpc/handler/GrpcHandler.java @@ -33,7 +33,7 @@ import io.a2a.spec.ContentTypeNotSupportedError; import io.a2a.spec.DeleteTaskPushNotificationConfigParams; import io.a2a.spec.EventKind; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.ExtensionSupportRequiredError; import io.a2a.spec.GetTaskPushNotificationConfigParams; import io.a2a.spec.InternalError; @@ -325,8 +325,11 @@ public void onComplete() { public void getExtendedAgentCard(io.a2a.grpc.GetExtendedAgentCardRequest request, StreamObserver responseObserver) { try { - responseObserver.onNext(ToProto.agentCard(getAgentCardInternal())); - responseObserver.onCompleted(); + AgentCard extendedAgentCard = getExtendedAgentCard(); + if (extendedAgentCard != null) { + responseObserver.onNext(ToProto.agentCard(extendedAgentCard)); + responseObserver.onCompleted(); + } } catch (Throwable t) { handleInternalError(responseObserver, t); } @@ -452,7 +455,7 @@ private void handleError(StreamObserver responseObserver, A2AError error) } else if (error instanceof InvalidAgentResponseError) { status = Status.INTERNAL; description = "InvalidAgentResponseError: " + error.getMessage(); - } else if (error instanceof ExtendedCardNotConfiguredError) { + } else if (error instanceof ExtendedAgentCardNotConfiguredError) { status = Status.FAILED_PRECONDITION; description = "ExtendedCardNotConfiguredError: " + error.getMessage(); } else if (error instanceof ExtensionSupportRequiredError) { @@ -498,6 +501,7 @@ private void handleInternalError(StreamObserver responseObserver, Throwab handleError(responseObserver, new InternalError(t.getMessage())); } + private AgentCard getAgentCardInternal() { AgentCard agentCard = getAgentCard(); if (initialised.compareAndSet(false, true)) { @@ -538,6 +542,8 @@ public static void setStreamingSubscribedRunnable(Runnable runnable) { protected abstract AgentCard getAgentCard(); + protected abstract AgentCard getExtendedAgentCard(); + protected abstract CallContextFactory getCallContextFactory(); protected abstract Executor getExecutor(); diff --git a/transport/grpc/src/test/java/io/a2a/transport/grpc/handler/GrpcHandlerTest.java b/transport/grpc/src/test/java/io/a2a/transport/grpc/handler/GrpcHandlerTest.java index a3ce7ca2a..690d69a87 100644 --- a/transport/grpc/src/test/java/io/a2a/transport/grpc/handler/GrpcHandlerTest.java +++ b/transport/grpc/src/test/java/io/a2a/transport/grpc/handler/GrpcHandlerTest.java @@ -12,6 +12,8 @@ import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicBoolean; +import jakarta.enterprise.inject.Instance; + import com.google.protobuf.Empty; import com.google.protobuf.Struct; import io.a2a.grpc.AuthenticationInfo; @@ -49,16 +51,13 @@ import io.a2a.spec.AgentInterface; import io.a2a.spec.Artifact; import io.a2a.spec.Event; -import io.a2a.spec.ExtensionSupportRequiredError; import io.a2a.spec.InternalError; -import io.a2a.spec.VersionNotSupportedError; import io.a2a.spec.MessageSendParams; import io.a2a.spec.TaskArtifactUpdateEvent; import io.a2a.spec.TaskStatusUpdateEvent; import io.a2a.spec.TextPart; import io.a2a.spec.UnsupportedOperationError; -import io.a2a.transport.grpc.context.GrpcContextKeys; -import io.grpc.Context; + import io.grpc.Status; import io.grpc.StatusRuntimeException; import io.grpc.internal.testing.StreamRecorder; @@ -194,7 +193,7 @@ public void testOnMessageNewMessageSuccess() throws Exception { Assertions.assertNotNull(result); Assertions.assertEquals(1, result.size()); SendMessageResponse response = result.get(0); - assertEquals(GRPC_MESSAGE, response.getMsg()); + assertEquals(GRPC_MESSAGE, response.getMessage()); } @Test @@ -210,7 +209,7 @@ public void testOnMessageNewMessageWithExistingTaskSuccess() throws Exception { Assertions.assertNotNull(result); Assertions.assertEquals(1, result.size()); SendMessageResponse response = result.get(0); - assertEquals(GRPC_MESSAGE, response.getMsg()); + assertEquals(GRPC_MESSAGE, response.getMessage()); } @Test @@ -316,8 +315,8 @@ public void testOnMessageStreamNewMessageSuccess() throws Exception { Assertions.assertNotNull(result); Assertions.assertEquals(1, result.size()); StreamResponse response = result.get(0); - Assertions.assertTrue(response.hasMsg()); - Message message = response.getMsg(); + Assertions.assertTrue(response.hasMessage()); + Message message = response.getMessage(); Assertions.assertEquals(GRPC_MESSAGE, message); } @@ -533,7 +532,7 @@ public void testOnResubscribeExistingTaskSuccess() throws Exception { // We need to send some events in order for those to end up in the queue SendMessageRequest sendMessageRequest = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder messageRecorder = StreamRecorder.create(); handler.sendStreamingMessage(sendMessageRequest, messageRecorder); @@ -545,8 +544,8 @@ public void testOnResubscribeExistingTaskSuccess() throws Exception { Assertions.assertNotNull(result); Assertions.assertEquals(1, result.size()); StreamResponse response = result.get(0); - Assertions.assertTrue(response.hasMsg()); - assertEquals(GRPC_MESSAGE, response.getMsg()); + Assertions.assertTrue(response.hasMessage()); + assertEquals(GRPC_MESSAGE, response.getMessage()); Assertions.assertNull(streamRecorder.getError()); } @@ -755,7 +754,7 @@ public void testDeletePushNotificationConfigNoPushConfigStore() { } @Disabled - public void testOnGetAuthenticatedExtendedAgentCard() throws Exception { + public void testOnGetExtendedAgentCard() throws Exception { // TODO - getting the authenticated extended agent card isn't supported for gRPC right now } @@ -843,13 +842,13 @@ public void testExtensionSupportRequiredErrorOnSendMessage() throws Exception { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); GrpcHandler handler = new TestGrpcHandler(cardWithExtension, requestHandler, internalExecutor); SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendMessage(request, streamRecorder); @@ -879,13 +878,13 @@ public void testExtensionSupportRequiredErrorOnSendStreamingMessage() throws Exc .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); GrpcHandler handler = new TestGrpcHandler(cardWithExtension, requestHandler, internalExecutor); SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendStreamingMessage(request, streamRecorder); @@ -915,7 +914,7 @@ public void testRequiredExtensionProvidedSuccess() throws Exception { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); // Create a TestGrpcHandler that provides the required extension in the context @@ -942,7 +941,7 @@ public ServerCallContext create(StreamObserver streamObserver) { }; SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendMessage(request, streamRecorder); @@ -989,7 +988,7 @@ public ServerCallContext create(StreamObserver streamObserver) { }; SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendMessage(request, streamRecorder); @@ -1034,7 +1033,7 @@ public ServerCallContext create(StreamObserver streamObserver) { }; SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendStreamingMessage(request, streamRecorder); @@ -1083,7 +1082,7 @@ public ServerCallContext create(StreamObserver streamObserver) { }; SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendMessage(request, streamRecorder); @@ -1134,7 +1133,7 @@ public ServerCallContext create(StreamObserver streamObserver) { }; SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendMessage(request, streamRecorder); @@ -1147,7 +1146,7 @@ public ServerCallContext create(StreamObserver streamObserver) { private StreamRecorder sendMessageRequest(GrpcHandler handler) throws Exception { SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendMessage(request, streamRecorder); @@ -1189,7 +1188,7 @@ private StreamRecorder getTaskPushNotificationConfig private StreamRecorder sendStreamingMessageRequest(GrpcHandler handler) throws Exception { SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); StreamRecorder streamRecorder = StreamRecorder.create(); handler.sendStreamingMessage(request, streamRecorder); @@ -1199,7 +1198,7 @@ private StreamRecorder sendStreamingMessageRequest(GrpcHandler h private void sendStreamingMessageRequest(GrpcHandler handler, StreamObserver streamObserver) throws Exception { SendMessageRequest request = SendMessageRequest.newBuilder() - .setRequest(GRPC_MESSAGE) + .setMessage(GRPC_MESSAGE) .build(); handler.sendStreamingMessage(request, streamObserver); } @@ -1218,7 +1217,7 @@ public void testListTasksNegativeTimestampReturnsInvalidArgument() { // Negative timestamp should trigger validation error ListTasksRequest request = ListTasksRequest.newBuilder() - .setLastUpdatedAfter(-1L) + .setStatusTimestampAfter(com.google.protobuf.Timestamp.newBuilder().setSeconds(-1L).build()) .setTenant("") .build(); @@ -1279,6 +1278,11 @@ protected AgentCard getAgentCard() { return card; } + @Override + protected AgentCard getExtendedAgentCard() { + return card; + } + @Override protected CallContextFactory getCallContextFactory() { return null; diff --git a/transport/jsonrpc/src/main/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandler.java b/transport/jsonrpc/src/main/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandler.java index ca8149099..2e1a1fdf0 100644 --- a/transport/jsonrpc/src/main/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandler.java +++ b/transport/jsonrpc/src/main/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandler.java @@ -14,8 +14,8 @@ import io.a2a.jsonrpc.common.wrappers.CancelTaskResponse; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigResponse; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardRequest; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardResponse; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardRequest; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskRequest; @@ -42,8 +42,7 @@ import io.a2a.server.version.A2AVersionValidator; import io.a2a.spec.A2AError; import io.a2a.spec.AgentCard; -import io.a2a.spec.ExtendedCardNotConfiguredError; -import io.a2a.spec.ExtensionSupportRequiredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.EventKind; import io.a2a.spec.InternalError; import io.a2a.spec.InvalidRequestError; @@ -53,7 +52,7 @@ import io.a2a.spec.Task; import io.a2a.spec.TaskNotFoundError; import io.a2a.spec.TaskPushNotificationConfig; -import io.a2a.spec.VersionNotSupportedError; + import mutiny.zero.ZeroPublisher; import org.jspecify.annotations.Nullable; @@ -262,18 +261,18 @@ public DeleteTaskPushNotificationConfigResponse deletePushNotificationConfig( } // TODO: Add authentication (https://github.com/a2aproject/a2a-java/issues/77) - public GetAuthenticatedExtendedCardResponse onGetAuthenticatedExtendedCardRequest( - GetAuthenticatedExtendedCardRequest request, ServerCallContext context) { - if (!agentCard.supportsExtendedAgentCard() || extendedAgentCard == null || !extendedAgentCard.isResolvable()) { - return new GetAuthenticatedExtendedCardResponse(request.getId(), - new ExtendedCardNotConfiguredError(null, "Extended Card not configured", null)); + public GetExtendedAgentCardResponse onGetExtendedCardRequest( + GetExtendedAgentCardRequest request, ServerCallContext context) { + if (!agentCard.capabilities().extendedAgentCard() || extendedAgentCard == null || !extendedAgentCard.isResolvable()) { + return new GetExtendedAgentCardResponse(request.getId(), + new ExtendedAgentCardNotConfiguredError(null, "Extended Card not configured", null)); } try { - return new GetAuthenticatedExtendedCardResponse(request.getId(), extendedAgentCard.get()); + return new GetExtendedAgentCardResponse(request.getId(), extendedAgentCard.get()); } catch (A2AError e) { - return new GetAuthenticatedExtendedCardResponse(request.getId(), e); + return new GetExtendedAgentCardResponse(request.getId(), e); } catch (Throwable t) { - return new GetAuthenticatedExtendedCardResponse(request.getId(), new InternalError(t.getMessage())); + return new GetExtendedAgentCardResponse(request.getId(), new InternalError(t.getMessage())); } } diff --git a/transport/jsonrpc/src/test/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandlerTest.java b/transport/jsonrpc/src/test/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandlerTest.java index 3436a34b1..b43c28029 100644 --- a/transport/jsonrpc/src/test/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandlerTest.java +++ b/transport/jsonrpc/src/test/java/io/a2a/transport/jsonrpc/handler/JSONRPCHandlerTest.java @@ -22,8 +22,8 @@ import io.a2a.jsonrpc.common.wrappers.CancelTaskResponse; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.DeleteTaskPushNotificationConfigResponse; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardRequest; -import io.a2a.jsonrpc.common.wrappers.GetAuthenticatedExtendedCardResponse; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardRequest; +import io.a2a.jsonrpc.common.wrappers.GetExtendedAgentCardResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigRequest; import io.a2a.jsonrpc.common.wrappers.GetTaskPushNotificationConfigResponse; import io.a2a.jsonrpc.common.wrappers.GetTaskRequest; @@ -52,14 +52,13 @@ import io.a2a.spec.AgentExtension; import io.a2a.spec.AgentInterface; import io.a2a.spec.Artifact; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.ExtensionSupportRequiredError; import io.a2a.spec.VersionNotSupportedError; import io.a2a.spec.DeleteTaskPushNotificationConfigParams; import io.a2a.spec.Event; import io.a2a.spec.GetTaskPushNotificationConfigParams; import io.a2a.spec.InternalError; -import io.a2a.spec.InvalidParamsError; import io.a2a.spec.InvalidRequestError; import io.a2a.spec.ListTasksParams; import io.a2a.spec.ListTaskPushNotificationConfigParams; @@ -1525,12 +1524,12 @@ public void testDeletePushNotificationConfigNoPushConfigStore() { } @Test - public void testOnGetAuthenticatedExtendedAgentCard() throws Exception { + public void testOnGetExtendedAgentCard() throws Exception { JSONRPCHandler handler = new JSONRPCHandler(CARD, requestHandler, internalExecutor); - GetAuthenticatedExtendedCardRequest request = new GetAuthenticatedExtendedCardRequest("1"); - GetAuthenticatedExtendedCardResponse response = handler.onGetAuthenticatedExtendedCardRequest(request, callContext); + GetExtendedAgentCardRequest request = new GetExtendedAgentCardRequest("1"); + GetExtendedAgentCardResponse response = handler.onGetExtendedCardRequest(request, callContext); assertEquals(request.getId(), response.getId()); - assertInstanceOf(ExtendedCardNotConfiguredError.class, response.getError()); + assertInstanceOf(ExtendedAgentCardNotConfiguredError.class, response.getError()); assertNull(response.getResult()); } @@ -1633,7 +1632,7 @@ public void testExtensionSupportRequiredErrorOnMessageSend() { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); JSONRPCHandler handler = new JSONRPCHandler(cardWithExtension, requestHandler, internalExecutor); @@ -1672,7 +1671,7 @@ public void testExtensionSupportRequiredErrorOnMessageSendStream() { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); JSONRPCHandler handler = new JSONRPCHandler(cardWithExtension, requestHandler, internalExecutor); @@ -1741,7 +1740,7 @@ public void testRequiredExtensionProvidedSuccess() { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); JSONRPCHandler handler = new JSONRPCHandler(cardWithExtension, requestHandler, internalExecutor); diff --git a/transport/rest/src/main/java/io/a2a/transport/rest/handler/RestHandler.java b/transport/rest/src/main/java/io/a2a/transport/rest/handler/RestHandler.java index 4d9a9667d..3ffb56c5f 100644 --- a/transport/rest/src/main/java/io/a2a/transport/rest/handler/RestHandler.java +++ b/transport/rest/src/main/java/io/a2a/transport/rest/handler/RestHandler.java @@ -36,7 +36,7 @@ import io.a2a.server.util.async.Internal; import io.a2a.spec.A2AError; import io.a2a.spec.AgentCard; -import io.a2a.spec.ExtendedCardNotConfiguredError; +import io.a2a.spec.ExtendedAgentCardNotConfiguredError; import io.a2a.spec.ContentTypeNotSupportedError; import io.a2a.spec.DeleteTaskPushNotificationConfigParams; import io.a2a.spec.EventKind; @@ -210,7 +210,7 @@ public HTTPRestResponse getTask(String taskId, @Nullable Integer historyLength, public HTTPRestResponse listTasks(@Nullable String contextId, @Nullable String status, @Nullable Integer pageSize, @Nullable String pageToken, - @Nullable Integer historyLength, @Nullable String lastUpdatedAfter, + @Nullable Integer historyLength, @Nullable String statusTimestampAfter, @Nullable Boolean includeArtifacts, String tenant, ServerCallContext context) { try { @@ -266,21 +266,21 @@ public HTTPRestResponse listTasks(@Nullable String contextId, @Nullable String s paramsBuilder.historyLength(historyLength); } paramsBuilder.tenant(tenant); - if (lastUpdatedAfter != null) { + if (statusTimestampAfter != null) { try { // Try parsing as Unix milliseconds first (integer) - long millis = Long.parseLong(lastUpdatedAfter); + long millis = Long.parseLong(statusTimestampAfter); if (millis < 0L) { Map errorData = new HashMap<>(); - errorData.put("parameter", "lastUpdatedAfter"); + errorData.put("parameter", "statusTimestampAfter"); errorData.put("reason", "Must be a non-negative timestamp value, got: " + millis); throw new InvalidParamsError(null, "Invalid params", errorData); } - paramsBuilder.lastUpdatedAfter(Instant.ofEpochMilli(millis)); + paramsBuilder.statusTimestampAfter(Instant.ofEpochMilli(millis)); } catch (NumberFormatException nfe) { // Fall back to ISO-8601 format try { - paramsBuilder.lastUpdatedAfter(Instant.parse(lastUpdatedAfter)); + paramsBuilder.statusTimestampAfter(Instant.parse(statusTimestampAfter)); } catch (DateTimeParseException e) { Map errorData = new HashMap<>(); errorData.put("parameter", "lastUpdatedAfter"); @@ -466,7 +466,7 @@ private int mapErrorToHttpStatus(A2AError error) { if (error instanceof InvalidAgentResponseError) { return 502; } - if (error instanceof ExtendedCardNotConfiguredError + if (error instanceof ExtendedAgentCardNotConfiguredError || error instanceof ExtensionSupportRequiredError) { return 400; } @@ -478,8 +478,8 @@ private int mapErrorToHttpStatus(A2AError error) { public HTTPRestResponse getExtendedAgentCard(String tenant) { try { - if (!agentCard.supportsExtendedAgentCard() || extendedAgentCard == null || !extendedAgentCard.isResolvable()) { - throw new ExtendedCardNotConfiguredError(null, "Extended Card not configured", null); + if (!agentCard.capabilities().extendedAgentCard() || extendedAgentCard == null || !extendedAgentCard.isResolvable()) { + throw new ExtendedAgentCardNotConfiguredError(null, "Extended Card not configured", null); } return new HTTPRestResponse(200, "application/json", JsonUtil.toJson(extendedAgentCard.get())); } catch (A2AError e) { diff --git a/transport/rest/src/test/java/io/a2a/transport/rest/handler/RestHandlerTest.java b/transport/rest/src/test/java/io/a2a/transport/rest/handler/RestHandlerTest.java index a2e6ef6e9..7d930415b 100644 --- a/transport/rest/src/test/java/io/a2a/transport/rest/handler/RestHandlerTest.java +++ b/transport/rest/src/test/java/io/a2a/transport/rest/handler/RestHandlerTest.java @@ -19,8 +19,6 @@ import io.a2a.spec.AgentCard; import io.a2a.spec.AgentExtension; import io.a2a.spec.AgentInterface; -import io.a2a.spec.ExtensionSupportRequiredError; -import io.a2a.spec.VersionNotSupportedError; import io.a2a.spec.Task; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; @@ -458,7 +456,7 @@ public void testExtensionSupportRequiredErrorOnSendMessage() { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); RestHandler handler = new RestHandler(cardWithExtension, requestHandler, internalExecutor); @@ -508,7 +506,7 @@ public void testExtensionSupportRequiredErrorOnSendStreamingMessage() { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); RestHandler handler = new RestHandler(cardWithExtension, requestHandler, internalExecutor); @@ -596,7 +594,7 @@ public void testRequiredExtensionProvidedSuccess() { .defaultInputModes(List.of("text")) .defaultOutputModes(List.of("text")) .skills(List.of()) - .protocolVersion(AgentCard.CURRENT_PROTOCOL_VERSION) + .protocolVersions(AgentCard.CURRENT_PROTOCOL_VERSION) .build(); RestHandler handler = new RestHandler(cardWithExtension, requestHandler, internalExecutor);