Skip to main content
Glama

get_overdue_milestones

Identify overdue project milestones in GitHub to track delays and manage deadlines effectively.

Instructions

Get a list of overdue milestones

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitYes
includeIssuesYes

Implementation Reference

  • Core implementation of the get_overdue_milestones tool logic. Fetches all milestones, filters for overdue open milestones (past due date and not closed/completed), sorts by due date ascending, limits to the specified number, and computes detailed metrics for each using getMilestoneMetrics.
    async getOverdueMilestones(limit: number = 10, includeIssues: boolean = false): Promise<MilestoneMetrics[]> {
      try {
        const milestones = await this.milestoneRepo.findAll();
        const now = new Date();
    
        const overdueMilestones = milestones.filter(milestone => {
          if (!milestone.dueDate) return false;
          const dueDate = new Date(milestone.dueDate);
          return now > dueDate && milestone.status !== ResourceStatus.COMPLETED && milestone.status !== ResourceStatus.CLOSED;
        });
    
        overdueMilestones.sort((a, b) => {
          if (!a.dueDate || !b.dueDate) return 0;
          return new Date(a.dueDate).getTime() - new Date(b.dueDate).getTime();
        });
    
        const limitedMilestones = overdueMilestones.slice(0, limit);
    
        const milestoneMetrics = await Promise.all(
          limitedMilestones.map(milestone =>
            this.getMilestoneMetrics(milestone.id, includeIssues)
          )
        );
    
        return milestoneMetrics;
      } catch (error) {
        throw this.mapErrorToMCPError(error);
      }
    }
  • MCP server tool handler dispatch: handles call_tool requests for get_overdue_milestones by delegating to ProjectManagementService.getOverdueMilestones.
    case "get_overdue_milestones":
      return await this.service.getOverdueMilestones(args.limit, args.includeIssues);
  • Zod input schema validation for get_overdue_milestones tool: requires positive integer limit and boolean includeIssues.
    // Schema for get_overdue_milestones tool
    export const getOverdueMilestonesSchema = z.object({
      limit: z.number().int().positive(),
      includeIssues: z.boolean(),
    });
    
    export type GetOverdueMilestonesArgs = z.infer<typeof getOverdueMilestonesSchema>;
  • Registers the get_overdue_milestones tool in the central ToolRegistry during initialization.
    this.registerTool(getOverdueMilestonesTool);
  • Full tool definition including name, description, schema reference, and usage examples for MCP list_tools response.
    export const getOverdueMilestonesTool: ToolDefinition<GetOverdueMilestonesArgs> = {
      name: "get_overdue_milestones",
      description: "Get a list of overdue milestones",
      schema: getOverdueMilestonesSchema as unknown as ToolSchema<GetOverdueMilestonesArgs>,
      examples: [
        {
          name: "List overdue milestones",
          description: "Get the top 5 overdue milestones",
          args: {
            limit: 5,
            includeIssues: false,
          },
        },
      ],
    };
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states it 'gets a list', implying a read-only operation, but doesn't cover permissions, rate limits, pagination, or response format. For a tool with two required parameters and no output schema, this leaves critical behavioral traits undocumented.

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 directly states the purpose without fluff. It's appropriately sized for a simple tool, though this conciseness comes at the cost of detail in other dimensions.

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 the tool's complexity (2 required parameters, no annotations, no output schema), the description is incomplete. It lacks parameter explanations, behavioral context, and output details, making it inadequate for reliable agent use without additional inference or trial-and-error.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate for undocumented parameters. It mentions no parameters at all, failing to explain 'limit' (e.g., max results) or 'includeIssues' (e.g., whether to fetch related issues). This leaves the agent guessing about input semantics beyond basic types.

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

Purpose3/5

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

The description 'Get a list of overdue milestones' clearly states the verb ('Get') and resource ('overdue milestones'), but it's vague about scope and doesn't distinguish from siblings like 'list_milestones' or 'get_upcoming_milestones'. It specifies the 'overdue' filter but doesn't clarify what constitutes 'overdue' or how results are determined.

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 like 'list_milestones' or 'get_upcoming_milestones'. The description implies it's for retrieving overdue items, but it doesn't specify prerequisites, context, or exclusions, leaving the agent to guess based on tool names alone.

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/HarshKumarSharma/MCP'

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