Skip to main content
Glama
nikydobrev

Azure DevOps Multi-Organization MCP Server

by nikydobrev

git_get_pull_request

Retrieve specific pull request details by ID from Azure DevOps organizations to monitor changes, review status, and track development progress across projects.

Instructions

Gets details of a specific pull request by ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
organizationYesThe name of the Azure DevOps organization
projectYesProject ID or name
pullRequestIdYesThe ID of the pull request

Implementation Reference

  • The handler function that executes the tool logic: retrieves the specific pull request details from Azure DevOps Git API using the provided organization, project, and pullRequestId, then returns the details as a JSON-formatted text response.
    async ({ organization, project, pullRequestId }) => {
      const connection = await connectionManager.getConnection(organization);
      const gitApi = await connection.getGitApi();
      const pr = await gitApi.getPullRequestById(pullRequestId, project);
      
      return {
        content: [{ type: "text", text: JSON.stringify(pr, null, 2) }],
      };
    }
  • The Zod input schema defining parameters: organization (string), project (string), pullRequestId (number). No explicit output schema; returns standardized MCP content.
    {
      organization: z.string().describe("The name of the Azure DevOps organization"),
      project: z.string().describe("Project ID or name"),
      pullRequestId: z.number().describe("The ID of the pull request"),
    },
  • The server.tool call that registers the 'git_get_pull_request' tool with the MCP server, including name, description, input schema, and handler function.
    server.tool(
      "git_get_pull_request",
      "Gets details of a specific pull request by ID",
      {
        organization: z.string().describe("The name of the Azure DevOps organization"),
        project: z.string().describe("Project ID or name"),
        pullRequestId: z.number().describe("The ID of the pull request"),
      },
      async ({ organization, project, pullRequestId }) => {
        const connection = await connectionManager.getConnection(organization);
        const gitApi = await connection.getGitApi();
        const pr = await gitApi.getPullRequestById(pullRequestId, project);
        
        return {
          content: [{ type: "text", text: JSON.stringify(pr, null, 2) }],
        };
      }
    );
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden. It states it 'Gets details' which implies a read-only operation, but doesn't disclose behavioral traits such as authentication needs, rate limits, error handling, or what 'details' include (e.g., status, comments, files). This is inadequate for a tool with no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with zero waste. It is front-loaded and appropriately sized for a simple retrieval tool, making it easy for an agent to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations, no output schema, and a read operation with three parameters, the description is incomplete. It doesn't explain what 'details' are returned, potential errors, or usage context, leaving significant gaps for the agent to understand the tool's behavior and output.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema fully documents the three parameters (organization, project, pullRequestId). The description adds no additional meaning beyond the schema, such as format examples or constraints, but the high coverage justifies the baseline score of 3.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Gets details') and resource ('a specific pull request by ID'), making the purpose unambiguous. However, it doesn't differentiate from sibling 'git_get_pull_requests' (plural) which likely lists multiple pull requests, so it misses explicit sibling distinction.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives. The description doesn't mention sibling tools like 'git_get_pull_requests' for listing multiple pull requests or 'git_get_item' for other Git items, leaving the agent without context for tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nikydobrev/mcp-server-azure-devops-multi'

If you have feedback or need assistance with the MCP directory API, please join our Discord server