Skip to main content
Glama

get_issue

Retrieve detailed information about a specific GitHub issue by providing repository owner, repository name, and issue number.

Instructions

Get details of a specific issue in a GitHub repository.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ownerYes
repoYes
issue_numberYes

Implementation Reference

  • The core handler function that executes the tool logic by making a GitHub API request to fetch the specified issue.
    export async function getIssue(github_pat: string, owner: string, repo: string, issue_number: number) {
      return githubRequest(github_pat, `https://api.github.com/repos/${owner}/${repo}/issues/${issue_number}`);
    }
  • Zod schemas for input validation: GetIssueSchema defines owner, repo, issue_number; _GetIssueSchema adds github_pat.
    export const GetIssueSchema = z.object({
      owner: z.string(),
      repo: z.string(),
      issue_number: z.number(),
    });
    
    export const _GetIssueSchema = GetIssueSchema.extend({
      github_pat: z.string().describe("GitHub Personal Access Token"),
    });
  • src/index.ts:158-162 (registration)
    Tool registration in the MCP server's listTools response, specifying name, description, and input schema.
    {
      name: "get_issue",
      description: "Get details of a specific issue in a GitHub repository.",
      inputSchema: zodToJsonSchema(issues.GetIssueSchema)
    },
  • src/index.ts:524-530 (registration)
    Dispatch logic in the CallToolRequest handler that validates arguments and invokes the getIssue handler.
    case "get_issue": {
      const args = issues._GetIssueSchema.parse(params.arguments);
      const issue = await issues.getIssue(args.github_pat, args.owner, args.repo, args.issue_number);
      return {
        content: [{ type: "text", text: JSON.stringify(issue, null, 2) }],
      };
    }
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. It states it 'gets details' but doesn't specify what details are returned (e.g., title, body, comments, labels), whether it requires authentication, rate limits, or error handling for non-existent issues. This leaves significant gaps for an agent to understand the tool's behavior beyond the basic operation.

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 front-loads the core action ('Get details') and resource. There's no wasted verbiage, repetition, or unnecessary elaboration, making it easy to parse quickly while conveying the essential purpose.

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 moderate complexity (3 required parameters, no annotations, no output schema), the description is incomplete. It lacks details on return values, error cases, authentication needs, and how it differs from sibling tools. For a read operation in a collaborative platform like GitHub, more context is needed to use it effectively without 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 'specific issue in a GitHub repository', which implies parameters for identifying the repository and issue, but doesn't explain what 'owner', 'repo', or 'issue_number' represent (e.g., GitHub username/organization, repository name, integer issue ID). This adds minimal value beyond what the parameter names suggest.

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 ('Get details') and resource ('specific issue in a GitHub repository'), making the purpose unambiguous. It distinguishes from siblings like 'list_issues' (which lists multiple) and 'update_issue' (which modifies), though it doesn't explicitly name these alternatives. The description avoids tautology by not just restating the name 'get_issue'.

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 when to prefer 'get_issue' over 'list_issues' for single-issue retrieval, or how it differs from 'search_issues' for filtered queries. There's no context about prerequisites, error conditions, or typical use cases beyond the basic action.

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

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