Skip to main content
Glama
Hint-Services

MCP Private GitHub Search

searchIssues

Find and track issues and discussions in private GitHub repositories using GitHub Issue Search syntax. Streamline task management and collaborative project workflows with accurate results.

Instructions

Search for issues and discussions in your Obsidian vault repository (johndoe-org/obsidian-vault). Great for tracking tasks, project management, and collaborative knowledge work.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesSearch query (uses GitHub Issue Search syntax)

Implementation Reference

  • Handler function that performs the searchIssues tool logic: constructs a GitHub search query for issues in the specified repo, calls the Octokit API to search issues and pull requests, formats the results as a markdown list, and returns them as text content.
    async ({ query }) => {
      const repoQualifier = `repo:${this.config.owner}/${this.config.repo}`;
      const qualifiedQuery = `${query} is:issue ${repoQualifier}`;
      const searchResults = await this.handleRequest(async () => {
        return this.octokit.search.issuesAndPullRequests({
          q: qualifiedQuery,
        });
      });
      // Format results as a markdown list
      const formattedResults = searchResults.items
        .map((item) => `- #${item.number} ${item.title} (${item.html_url})`)
        .join("\n");
      return {
        // Return formatted text instead of raw JSON string
        content: [
          {
            type: "text" as const,
            text: `Found ${searchResults.total_count} issues:\n${formattedResults}`,
          },
        ],
      };
    }
  • Zod schema defining the input parameter 'query' for the searchIssues tool.
    query: z
      .string()
      .describe("Search query (uses GitHub Issue Search syntax)"),
  • Full registration of the 'searchIssues' tool using server.tool(), including tool name, description, input schema, execution hints, and the handler function.
    server.tool(
      "searchIssues",
      `Search for issues and discussions in your Obsidian vault repository (${this.config.owner}/${this.config.repo}). Great for tracking tasks, project management, and collaborative knowledge work.`,
      {
        query: z
          .string()
          .describe("Search query (uses GitHub Issue Search syntax)"),
      },
      {
        readOnlyHint: true,
        destructiveHint: false,
        idempotentHint: true,
        openWorldHint: true,
      },
      async ({ query }) => {
        const repoQualifier = `repo:${this.config.owner}/${this.config.repo}`;
        const qualifiedQuery = `${query} is:issue ${repoQualifier}`;
        const searchResults = await this.handleRequest(async () => {
          return this.octokit.search.issuesAndPullRequests({
            q: qualifiedQuery,
          });
        });
        // Format results as a markdown list
        const formattedResults = searchResults.items
          .map((item) => `- #${item.number} ${item.title} (${item.html_url})`)
          .join("\n");
        return {
          // Return formatted text instead of raw JSON string
          content: [
            {
              type: "text" as const,
              text: `Found ${searchResults.total_count} issues:\n${formattedResults}`,
            },
          ],
        };
      }
    );
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It mentions the repository (johndoe-org/obsidian-vault) and general use cases, but lacks details on behavioral traits like pagination, rate limits, authentication needs, or what 'discussions' entails. For a search tool with zero annotation coverage, this is insufficient, though it's not misleading.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, front-loaded with the core purpose and followed by use cases. It's efficient with minimal waste, though the use-case list could be slightly trimmed for optimal conciseness, preventing a perfect score.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/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 (search with one parameter), no annotations, and no output schema, the description is adequate but incomplete. It covers purpose and context but lacks details on behavior, return values, or error handling, making it just viable for basic use.

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?

Schema description coverage is 100%, with the parameter 'query' documented as using 'GitHub Issue Search syntax.' The description adds no additional parameter information beyond this, so it meets the baseline of 3 where the schema does the heavy lifting without compensating for gaps.

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 tool searches for 'issues and discussions' in a specific repository, with the verb 'search' and resource 'issues and discussions' identified. It distinguishes from sibling tools like getCommitHistory and searchFiles by focusing on issues rather than commits or files. However, it doesn't explicitly differentiate from potential issue-specific siblings (none listed), so it's not a perfect 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for 'tracking tasks, project management, and collaborative knowledge work,' suggesting context but not explicit when-to-use guidance. It doesn't mention when to use this vs. alternatives like searchFiles or provide exclusions. The guidance is helpful but not comprehensive enough for a higher score.

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/Hint-Services/mcp-private-github-search'

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