[azure.ai.agents] Use v1 for endpoint requests#8347
Open
glharper wants to merge 4 commits into
Open
Conversation
Use v1 for hosted agent endpoint protocol and session requests while preserving the preview version for management APIs. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
📋 Prioritization NoteThanks for the contribution! The linked issue isn't in the current milestone yet. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the Azure AI Agents extension to use api-version=v1 for hosted agent endpoint protocol URLs and session lifecycle requests, while keeping agent management/deploy/eval/file/doctor APIs on 2025-11-15-preview (per issue #8329).
Changes:
- Introduces a single source of truth constant (
AgentEndpointAPIVersion = "v1") for hosted endpoint protocol + session requests. - Updates endpoint URL generation/help text to emit
api-version=v1and adjusts related unit tests. - Threads the endpoint API version through remote invoke session creation and LRO polling.
Reviewed changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| cli/azd/extensions/azure.ai.agents/internal/project/service_target_agent.go | Switches displayed protocol endpoint URLs to use the hosted endpoint API version constant. |
| cli/azd/extensions/azure.ai.agents/internal/project/service_target_agent_test.go | Updates endpoint URL expectations to api-version=v1 and improves symlink skip logic. |
| cli/azd/extensions/azure.ai.agents/internal/pkg/paths/paths_test.go | Improves symlink skip logic for permission-related failures. |
| cli/azd/extensions/azure.ai.agents/internal/pkg/agents/agent_api/operations_test.go | Updates session API version in tests to use the new endpoint API version constant. |
| cli/azd/extensions/azure.ai.agents/internal/pkg/agents/agent_api/api_versions.go | Adds AgentEndpointAPIVersion = "v1" constant. |
| cli/azd/extensions/azure.ai.agents/internal/cmd/show_test.go | Updates expected shown endpoint URLs to api-version=v1. |
| cli/azd/extensions/azure.ai.agents/internal/cmd/session.go | Uses hosted endpoint API version for session create/show/delete/list commands. |
| cli/azd/extensions/azure.ai.agents/internal/cmd/invoke.go | Updates invoke help/example URLs and threads API version through version-session creation + LRO fallback polling. |
| cli/azd/extensions/azure.ai.agents/internal/cmd/invoke_test.go | Updates URL validation and function seams to account for the new API version parameter. |
| cli/azd/extensions/azure.ai.agents/internal/cmd/agent_endpoint_test.go | Updates parsed/built endpoint URL expectations to api-version=v1 and preserves custom versions. |
| cli/azd/extensions/azure.ai.agents/internal/cmd/agent_context.go | Exposes AgentEndpointAPIVersion in cmd package as an alias to the agent_api constant. |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
trangevi
requested changes
May 26, 2026
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
api-version=v1for Azure AI Agents hosted endpoint protocol and session requests2025-11-15-previewFixes #8329
Testing
go test ./...golangci-lint run ./...