point URL to agent, not to agentcard (#3176)

This commit is contained in:
Korolev Dmitry
2026-01-13 17:32:05 +01:00
committed by GitHub
Unverified
parent 9c094573e8
commit 5faa2851bb
2 changed files with 4 additions and 8 deletions
@@ -90,13 +90,7 @@ public static class AIAgentExtensions
// we can help user if they did not set Url explicitly.
if (string.IsNullOrEmpty(agentCard.Url))
{
var agentCardUrl = context.TrimEnd('/');
if (!context.EndsWith("/v1/card", StringComparison.Ordinal))
{
agentCardUrl += "/v1/card";
}
agentCard.Url = agentCardUrl;
agentCard.Url = context.TrimEnd('/');
}
return Task.FromResult(agentCard);