Skip to main content
Glama
ennuiii

Azure DevOps MCP Server with PAT Authentication

by ennuiii

wit_get_work_items_for_iteration

Retrieve work items for a specific iteration in Azure DevOps using project and iteration IDs. Facilitates tracking and management of tasks within defined development cycles.

Instructions

Retrieve a list of work items for a specified iteration.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
iterationIdYesThe ID of the iteration to retrieve work items for.
projectYesThe name or ID of the Azure DevOps project.
teamNoThe name or ID of the Azure DevOps team. If not provided, the default team will be used.

Implementation Reference

  • The handler function that executes the tool logic: connects to Azure DevOps, gets the WorkApi, and retrieves work items for the specified iteration using getIterationWorkItems.
    const connection = await connectionProvider(); const workApi = await connection.getWorkApi(); //get the work items for the current iteration const workItems = await workApi.getIterationWorkItems({ project, team }, iterationId); return { content: [{ type: "text", text: JSON.stringify(workItems, null, 2) }], }; } );
  • Zod input schema defining parameters: project (string), team (optional string), iterationId (string).
    project: z.string().describe("The name or ID of the Azure DevOps project."), team: z.string().optional().describe("The name or ID of the Azure DevOps team. If not provided, the default team will be used."), iterationId: z.string().describe("The ID of the iteration to retrieve work items for."), }, async ({ project, team, iterationId }) => {
  • Registers the tool 'wit_get_work_items_for_iteration' with McpServer.tool, including description, input schema, and handler.
    WORKITEM_TOOLS.get_work_items_for_iteration, "Retrieve a list of work items for a specified iteration.", { project: z.string().describe("The name or ID of the Azure DevOps project."), team: z.string().optional().describe("The name or ID of the Azure DevOps team. If not provided, the default team will be used."), iterationId: z.string().describe("The ID of the iteration to retrieve work items for."), }, async ({ project, team, iterationId }) => { const connection = await connectionProvider(); const workApi = await connection.getWorkApi(); //get the work items for the current iteration const workItems = await workApi.getIterationWorkItems({ project, team }, iterationId); return { content: [{ type: "text", text: JSON.stringify(workItems, null, 2) }], }; } );
  • Constant mapping the internal tool key to the MCP tool name 'wit_get_work_items_for_iteration'.
    get_work_items_for_iteration: "wit_get_work_items_for_iteration",

Other Tools

Related 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/ennuiii/DevOpsMcpPAT'

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