Skip to main content
Glama

create_milestone

Create GitHub milestones to organize project timelines, track progress, and manage deliverables with clear due dates and descriptions.

Instructions

Create a new milestone

Input Schema

NameRequiredDescriptionDefault
titleYes
descriptionYes
dueDateNo

Input Schema (JSON Schema)

{ "properties": { "description": { "type": "string" }, "dueDate": { "type": "string" }, "title": { "type": "string" } }, "required": [ "title", "description" ], "type": "object" }

Implementation Reference

  • Main handler function that executes the create_milestone tool logic by creating a GitHub milestone via the repository.
    async createMilestone(data: { title: string; description: string; dueDate?: string; }): Promise<Milestone> { try { const milestoneData: CreateMilestone = { title: data.title, description: data.description, dueDate: data.dueDate, }; return await this.milestoneRepo.create(milestoneData); } catch (error) { throw this.mapErrorToMCPError(error); } }
  • Zod schema defining input validation for the create_milestone tool.
    // Schema for create_milestone tool export const createMilestoneSchema = z.object({ title: z.string().min(1, "Milestone title is required"), description: z.string().min(1, "Milestone description is required"), dueDate: z.string().datetime("Due date must be a valid ISO date string").optional(), }); export type CreateMilestoneArgs = z.infer<typeof createMilestoneSchema>;
  • Registration of the create_milestone tool in the central ToolRegistry.
    // Register milestone tools this.registerTool(createMilestoneTool); this.registerTool(listMilestonesTool); this.registerTool(updateMilestoneTool); this.registerTool(deleteMilestoneTool);
  • MCP tool dispatch handler that routes create_milestone calls to the service implementation.
    case "create_milestone": return await this.service.createMilestone(args);
  • ToolDefinition object for create_milestone including name, description, schema, and examples used for MCP tool listing.
    export const createMilestoneTool: ToolDefinition<CreateMilestoneArgs> = { name: "create_milestone", description: "Create a new milestone", schema: createMilestoneSchema as unknown as ToolSchema<CreateMilestoneArgs>, examples: [ { name: "Create milestone with due date", description: "Create a milestone with title, description and due date", args: { title: "Beta Release", description: "Complete all features for beta release", dueDate: "2025-06-30T00:00:00Z" } } ] };

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