Skip to main content
Glama
mcollina

GitHub Notifications MCP Server

delete-thread-subscription

Stop receiving notifications for a specific GitHub thread by unsubscribing from it using the thread ID.

Instructions

Unsubscribe from a GitHub notification thread

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
thread_idYesThe ID of the notification thread to unsubscribe from

Implementation Reference

  • The handler function that executes the delete-thread-subscription tool logic by calling the GitHub API to delete the subscription.
    export async function deleteThreadSubscriptionHandler(args: z.infer<typeof deleteThreadSubscriptionSchema>) {
      try {
        // Make request to GitHub API
        await githubDelete(`/notifications/threads/${args.thread_id}/subscription`);
    
        return {
          content: [{
            type: "text",
            text: `Successfully unsubscribed from thread ${args.thread_id}.`
          }]
        };
      } catch (error) {
        if (error instanceof Error && error.message.includes("404")) {
          return {
            content: [{
              type: "text",
              text: `You were not subscribed to thread ${args.thread_id}.`
            }]
          };
        }
        
        return {
          isError: true,
          content: [{
            type: "text",
            text: formatError(`Failed to unsubscribe from thread ${args.thread_id}`, error)
          }]
        };
      }
    }
  • Zod schema defining the input parameters for the delete-thread-subscription tool (thread_id).
    export const deleteThreadSubscriptionSchema = z.object({
      thread_id: z.string().describe("The ID of the notification thread to unsubscribe from")
    });
  • Function that registers the delete-thread-subscription tool with the MCP server.
    export function registerDeleteThreadSubscriptionTool(server: any) {
      server.tool(
        "delete-thread-subscription",
        "Unsubscribe from a GitHub notification thread",
        deleteThreadSubscriptionSchema.shape,
        deleteThreadSubscriptionHandler
      );
    }
  • src/server.ts:45-45 (registration)
    Call to register the delete-thread-subscription tool during server initialization.
    registerDeleteThreadSubscriptionTool(server);
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 of behavioral disclosure. It states the action ('Unsubscribe') but does not describe effects (e.g., whether this is permanent, if it affects other users, or what happens to the thread), permissions required, or error handling. For a mutation tool with zero annotation coverage, this is a significant gap.

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 with zero waste. It is front-loaded with the core action and resource, making it immediately understandable without unnecessary elaboration.

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 complexity (a mutation with one parameter), lack of annotations, and no output schema, the description is minimally adequate. It states the purpose but lacks details on behavior, outcomes, or error conditions, which are important for a destructive operation. It meets basic requirements but leaves gaps in understanding the tool's full impact.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with the single parameter 'thread_id' fully documented in the schema. The description does not add parameter details beyond the schema, but with only one parameter and high schema coverage, the baseline is appropriately high. No additional semantic context is needed.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Unsubscribe from') and resource ('a GitHub notification thread'), distinguishing it from sibling tools like 'get-thread-subscription' or 'set-thread-subscription'. It precisely communicates the tool's function without ambiguity.

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 context (unsubscribing from notifications) but does not explicitly state when to use this tool versus alternatives like 'manage-repo-subscription' or 'set-thread-subscription'. No guidance on prerequisites or exclusions is provided, leaving usage decisions to inference.

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

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