Skip to main content
Glama

create_issue

Create and manage GitHub repository issues by specifying an owner, repository, title, description, assignees, milestones, and labels directly through the server.

Instructions

Create a new issue in a GitHub repository

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
assigneesNo
bodyNo
labelsNo
milestoneNo
ownerYes
repoYes
titleYes

Implementation Reference

  • Core handler function that executes the GitHub API POST request to create a new issue in the repository.
    export async function createIssue(
      owner: string,
      repo: string,
      options: z.infer<typeof CreateIssueOptionsSchema>
    ) {
      return githubRequest(
        `https://api.github.com/repos/${owner}/${repo}/issues`,
        {
          method: "POST",
          body: options,
        }
      );
    }
  • MCP CallTool handler case that parses input schema, extracts parameters, calls the core createIssue function, and formats the response.
    case "create_issue": {
      const args = issues.CreateIssueSchema.parse(request.params.arguments);
      const { owner, repo, ...options } = args;
      const issue = await issues.createIssue(owner, repo, options);
      return {
        content: [{ type: "text", text: JSON.stringify(issue, null, 2) }],
      };
    }
  • index.ts:96-99 (registration)
    Tool registration in the ListToolsRequestHandler response array, defining name, description, and input JSON schema.
      name: "create_issue",
      description: "Create a new issue in a GitHub repository",
      inputSchema: zodToJsonSchema(issues.CreateIssueSchema),
    },
  • Composite Zod schema for the full create_issue input, including owner, repo, and options.
    export const CreateIssueSchema = z.object({
      owner: z.string(),
      repo: z.string(),
      ...CreateIssueOptionsSchema.shape,
    });
  • Zod schema defining the options for creating an issue (title, body, assignees, etc.). Used in CreateIssueSchema.
    export const CreateIssueOptionsSchema = z.object({
      title: z.string(),
      body: z.string().optional(),
      assignees: z.array(z.string()).optional(),
      milestone: z.number().optional(),
      labels: z.array(z.string()).optional(),
    });
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure but offers minimal information. It states it creates an issue but doesn't describe what happens after creation (e.g., issue number assignment, notifications), authentication requirements, rate limits, error conditions, or whether the operation is idempotent. For a mutation tool with zero annotation coverage, this leaves significant behavioral gaps.

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 gets straight to the point with zero wasted words. It's appropriately front-loaded with the core action and resource, making it easy to parse quickly despite its brevity.

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 7 parameters, 0% schema description coverage, no annotations, and no output schema, the description is insufficiently complete. It covers the basic purpose but lacks crucial details about parameters, behavioral expectations, error handling, and output format. The agent would need to guess about many aspects of tool invocation.

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?

With 0% schema description coverage for 7 parameters, the description provides no parameter information beyond what's implied by the tool name. It doesn't explain what 'owner', 'repo', 'title', 'body', 'assignees', 'labels', or 'milestone' represent, their formats, or constraints. The description fails to compensate for the complete lack of schema documentation.

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 action ('Create a new issue') and target resource ('in a GitHub repository'), making the purpose immediately understandable. It distinguishes itself from sibling tools like 'update_issue' or 'get_issue' by specifying creation rather than modification or retrieval. However, it doesn't explicitly differentiate from other creation tools like 'create_project' or 'create_pull_request' beyond the resource type.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., repository access), when not to use it (e.g., for updating existing issues), or how it differs from similar creation tools like 'create_pull_request'. The agent must infer usage from the tool name and context 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

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