Skip to main content
Glama

create_project

Generate a new project in a GitHub repository using owner, repo, and name inputs. Add a description to organize tasks, track progress, and manage workflows effectively.

Instructions

Create a new project for a repository

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyNoThe description of the project
nameYesThe name of the project
ownerYesRepository owner (username or organization)
repoYesRepository name

Implementation Reference

  • Core handler function that performs the POST request to GitHub API to create a project in a repository.
    export async function createProject( github_pat: string, owner: string, repo: string, name: string, body?: string ): Promise<z.infer<typeof ProjectSchema>> { const response = await githubRequest( github_pat, `https://api.github.com/repos/${owner}/${repo}/projects`, { method: "POST", body: { name, body, }, headers: { "Accept": "application/vnd.github.inertia-preview+json", }, } ); return ProjectSchema.parse(response); }
  • Input schema validation for create_project tool, including public schema and internal version with github_pat.
    export const CreateProjectSchema = z.object({ owner: z.string().describe("Repository owner (username or organization)"), repo: z.string().describe("Repository name"), name: z.string().describe("The name of the project"), body: z.string().optional().describe("The description of the project"), }); export const _CreateProjectSchema = CreateProjectSchema.extend({ github_pat: z.string().describe("GitHub Personal Access Token"), });
  • src/index.ts:254-258 (registration)
    MCP tool registration in the server, defining name, description, and input schema.
    { name: "create_project", description: "Create a new project for a repository", inputSchema: zodToJsonSchema(projects.CreateProjectSchema), },
  • MCP server dispatch handler that validates arguments and delegates to the projects.createProject function.
    case "create_project": { const args = projects._CreateProjectSchema.parse(params.arguments); const { github_pat, owner, repo, name, body } = args; const result = await projects.createProject(github_pat, owner, repo, name, body); return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }], }; }

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/MissionSquad/mcp-github'

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