Skip to main content
Glama

update_project

Modify project details such as name, description, or status directly within the GitHub MCP Server. Streamline project management by updating essential information efficiently.

Instructions

Update an existing project's details

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyNoNew description of the project
nameNoNew name of the project
project_idYesThe unique identifier of the project
stateNoState of the project

Implementation Reference

  • The main handler function that executes the tool logic by making a PATCH request to the GitHub Projects API to update the project's name, body, and/or state.
    export async function updateProject(projectId: number, name?: string, body?: string, state?: string) {
        try {
            const url = `https://api.github.com/projects/${projectId}`;
    
            const updateData: Record<string, any> = {};
    
            if (name !== undefined) {
                updateData.name = name;
            }
    
            if (body !== undefined) {
                updateData.body = body;
            }
    
            if (state !== undefined) {
                updateData.state = state;
            }
    
            const response = await githubRequest(url, {
                method: 'PATCH',
                body: updateData,
                headers: {
                    'Accept': 'application/vnd.github.inertia-preview+json'
                }
            });
    
            return response;
        } catch (error) {
            if (error instanceof GitHubError) {
                throw error;
            }
    
            throw new GitHubError(`Failed to update project: ${(error as Error).message}`, 500, { error: (error as Error).message });
        }
    }
  • Zod input schema defining the parameters for updating a project: project_id (required), name/body/state (optional).
    export const UpdateProjectSchema = z.object({
        project_id: z.number().describe("The unique identifier of the project"),
        name: z.string().optional().describe("New name of the project"),
        body: z.string().optional().describe("New description of the project"),
        state: z.enum(["open", "closed"]).optional().describe("State of the project"),
    });
  • index.ts:216-219 (registration)
    Tool registration in the MCP server's ListTools response, specifying name, description, and input schema.
      name: "update_project",
      description: "Update an existing project's details",
      inputSchema: zodToJsonSchema(projects.UpdateProjectSchema),
    },
  • MCP server dispatch handler for 'update_project' tool call: parses input with schema and invokes the projects.updateProject function.
    case "update_project": {
      const args = projects.UpdateProjectSchema.parse(request.params.arguments);
      const result = await projects.updateProject(
        args.project_id,
        args.name,
        args.body,
        args.state
      );
      return {
        content: [{ type: "text", text: JSON.stringify(result, null, 2) }],
      };
    }
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 this is an update operation, implying mutation, but doesn't cover permissions, side effects, error conditions, or response format. For a mutation tool with zero annotation coverage, this leaves significant gaps in understanding how it behaves.

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 that directly states the tool's function without any unnecessary words. It's front-loaded and wastes no space, making it easy 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?

For a mutation tool with no annotations and no output schema, the description is insufficient. It doesn't explain what happens during the update, potential impacts, or what is returned. Given the complexity of updating a project and the lack of structured data, more context is needed to make this tool usable.

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?

The schema description coverage is 100%, so all parameters are documented in the schema itself. The description doesn't add any additional meaning or context beyond what's in the schema, such as explaining relationships between parameters or usage examples. Baseline 3 is appropriate when the schema does the heavy lifting.

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 verb ('update') and resource ('an existing project's details'), making the purpose unambiguous. However, it doesn't differentiate from sibling tools like 'update_project_column' or 'update_project_v2', which also update project-related entities, so it doesn't fully distinguish itself from alternatives.

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 'update_project_column' or 'update_project_v2', nor are there any prerequisites or exclusions mentioned. The description only restates the basic function without contextual usage information.

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

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

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