Skip to content

Conversation

@JesuTerraz
Copy link
Contributor

No description provided.

@JesuTerraz JesuTerraz marked this pull request as ready for review December 9, 2025 23:19
@JesuTerraz JesuTerraz requested a review from a team as a code owner December 9, 2025 23:19
Copilot AI review requested due to automatic review settings December 9, 2025 23:19
@JesuTerraz JesuTerraz enabled auto-merge (squash) December 9, 2025 23:19
Copy link
Contributor

Copilot AI left a 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 PR adds User-Agent header support to all MCP (Model Context Protocol) server HTTP requests across the tooling SDK and its extensions. The User-Agent header identifies the SDK version, operating system, Python version, and the specific orchestration framework being used (SemanticKernel, OpenAI, AzureAIFoundry, or AgentFramework), enabling better telemetry and diagnostics.

Key Changes:

  • Added USER_AGENT constant to the Constants.Headers class for consistent header naming
  • Integrated User-Agent headers in MCP server configuration service for gateway requests
  • Added framework-specific User-Agent headers across all four MCP tool registration services

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/utils/constants.py Added USER_AGENT constant to Headers class for centralized header name management
libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/services/mcp_tool_server_configuration_service.py Added User-Agent header to gateway requests using RuntimeUtility.get_user_agent_header()
libraries/microsoft-agents-a365-tooling-extensions-semantickernel/microsoft_agents_a365/tooling/extensions/semantickernel/services/mcp_tool_registration_service.py Added User-Agent header with "SemanticKernel" orchestrator identifier
libraries/microsoft-agents-a365-tooling-extensions-openai/microsoft_agents_a365/tooling/extensions/openai/mcp_tool_registration_service.py Added User-Agent header with "OpenAI" orchestrator identifier and updated Authorization header to use constant
libraries/microsoft-agents-a365-tooling-extensions-azureaifoundry/microsoft_agents_a365/tooling/extensions/azureaifoundry/services/mcp_tool_registration_service.py Added User-Agent header with "AzureAIFoundry" orchestrator identifier
libraries/microsoft-agents-a365-tooling-extensions-agentframework/microsoft_agents_a365/tooling/extensions/agentframework/services/mcp_tool_registration_service.py Added User-Agent header with "AgentFramework" orchestrator identifier

Copilot AI review requested due to automatic review settings December 9, 2025 23:50
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Comments suppressed due to low confidence (3)

libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/services/mcp_tool_server_configuration_service.py:341

  • Inconsistent use of hardcoded string "User-Agent" instead of the constant Constants.Headers.USER_AGENT that was just added. For consistency with the Authorization header on line 340 and usage elsewhere in the codebase, this should use the constant.
            Dictionary of HTTP headers.

libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/services/mcp_tool_server_configuration_service.py:80

  • Missing documentation for the new orchestrator_name parameter. The docstring should include a description of this parameter in the Args section, such as:
orchestrator_name: Optional orchestrator name to include in User-Agent header.
        """
        Gets the list of MCP Servers that are configured for the agent.

        Args:
            agentic_app_id: Agentic App ID for the agent.
            auth_token: Authentication token to access the MCP servers.

libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/services/mcp_tool_server_configuration_service.py:289

  • Missing documentation for the new orchestrator_name parameter. The docstring should include a description of this parameter in the Args section, such as:
orchestrator_name: Optional orchestrator name to include in User-Agent header.
        self, agentic_app_id: str, auth_token: str, orchestrator_name: Optional[str] = None
    ) -> List[MCPServerConfig]:
        """
        Reads MCP server configurations from tooling gateway endpoint for production scenario.

        Args:
            agentic_app_id: Agentic App ID for the agent.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

mrunalhirve128
mrunalhirve128 previously approved these changes Dec 10, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.

Comments suppressed due to low confidence (1)

libraries/microsoft-agents-a365-tooling/microsoft_agents_a365/tooling/models/init.py:11

  • The name 'ToolOptions' is exported by all but is not defined.
__all__ = ["MCPServerConfig", "ToolOptions"]

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated no new comments.

@JesuTerraz JesuTerraz merged commit 6fc9c44 into main Dec 15, 2025
14 checks passed
@JesuTerraz JesuTerraz deleted the users/jterrazas/use-user-agent-header branch December 15, 2025 21:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants