-
Notifications
You must be signed in to change notification settings - Fork 268
[AI Agents Extension] Retrieve AppInsights Connection #6468
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: trangevi <trangevi@microsoft.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This pull request adds functionality to retrieve Application Insights connection credentials from Microsoft Foundry projects. When a project-id is provided, the extension now fetches existing Application Insights connections with their credentials and configures them for the agent.
Key changes:
- Added a new API method
GetConnectionWithCredentialsto fetch connection details including sensitive credentials - Enhanced connection filtering to detect and process Application Insights connections separately
- Implemented user prompts for selecting or manually entering Application Insights connection strings when multiple connections exist or none are found
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| cli/azd/extensions/azure.ai.agents/internal/pkg/azure/foundry_projects_client.go | Added GetConnectionWithCredentials method to retrieve connections with credentials via POST endpoint; added Key field to BaseCredentials struct to store credential keys |
| cli/azd/extensions/azure.ai.agents/internal/cmd/init.go | Enhanced connection filtering to handle Application Insights connections; added logic to retrieve credentials, prompt users for selection when multiple connections exist, and set the APPLICATIONINSIGHTS_CONNECTION_STRING environment variable |
cli/azd/extensions/azure.ai.agents/internal/pkg/azure/foundry_projects_client.go
Show resolved
Hide resolved
Signed-off-by: trangevi <trangevi@microsoft.com>
If a project-id is provided, retrieve an existing Application Insights connection if exists