Skip to content

Commit 6a22243

Browse files
authored
fix: use SERVER_URL constant in A2ACardResolver constructor in HelloWorldClient #664 (#666)
## Description Replace the hardcoded string literal `"http://localhost:9999"` with the existing `SERVER_URL` constant in the `A2ACardResolver` constructor call inside `HelloWorldClient`. Fixes #664 🦕
1 parent 841675b commit 6a22243

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

examples/helloworld/client/src/main/java/io/a2a/examples/helloworld/HelloWorldClient.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public class HelloWorldClient {
5353
public static void main(String[] args) {
5454
OpenTelemetrySdk openTelemetrySdk = null;
5555
try {
56-
AgentCard publicAgentCard = new A2ACardResolver("http://localhost:9999").getAgentCard();
56+
AgentCard publicAgentCard = new A2ACardResolver(SERVER_URL).getAgentCard();
5757
System.out.println("Successfully fetched public agent card:");
5858
System.out.println(JsonUtil.toJson(publicAgentCard));
5959
System.out.println("Using public agent card for client initialization (default).");

0 commit comments

Comments
 (0)