Skip to main content
Glama
burkeholland

VS Code MCP Button Generator

by burkeholland

Copilot install buttons (raw URL)

copilot_buttons_from_raw

Generate VS Code install buttons for raw URLs containing chat instructions, prompts, or modes to enable quick setup of MCP server configurations.

Instructions

Generate VS Code install buttons for a raw URL to chat instructions, prompts, or chat modes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
kindYesInstall kind
urlYesRaw GitHub URL or any public raw URL to the file.

Implementation Reference

  • src/index.ts:150-164 (registration)
    Registration of the MCP tool 'copilot_buttons_from_raw'. Includes title, description, input schema validating 'kind' (enum) and 'url' (string url), and handler that invokes generateCopilotInstallButtons to produce markdown content.
    server.registerTool(
      "copilot_buttons_from_raw",
      {
        title: "Copilot install buttons (raw URL)",
        description: "Generate VS Code install buttons for a raw URL to chat instructions, prompts, or chat modes.",
        inputSchema: {
          kind: z.enum(["chat-instructions", "chat-prompt", "chat-mode"]).describe("Install kind"),
          url: z.string().url().describe("Raw GitHub URL or any public raw URL to the file."),
        }
      },
      async ({ kind, url }) => {
        const markdown = generateCopilotInstallButtons(kind, url);
        return { content: [{ type: "text", text: markdown }] };
      }
    );
  • Main execution logic for the tool: generateCopilotInstallButtons constructs VS Code Stable and Insiders markdown install buttons (badges + links) for Copilot chat instructions/prompts/modes from the raw URL.
    export function generateCopilotInstallButtons(kind: CopilotInstallKind, rawUrl: string): string {
      const stableBadge = makeInstallBadge('0098FF', 'VS_Code');
      const insidersBadge = makeInstallBadge('24bfa5', 'VS_Code_Insiders');
      const stableLink = buildCopilotInstallLink(kind, rawUrl, false);
      const insidersLink = buildCopilotInstallLink(kind, rawUrl, true);
      const stable = `[![Install in VS Code](${stableBadge})](${stableLink})`;
      const insiders = `[![Install in VS Code](${insidersBadge})](${insidersLink})`;
      return `${stable}\n${insiders}`;
    }
  • Helper function to build the VS Code redirect install link with proper URL encoding for scheme, kind, and rawUrl.
    function buildCopilotInstallLink(kind: CopilotInstallKind, rawUrl: string, insiders = false) {
      const scheme = insiders ? 'vscode-insiders' : 'vscode';
      const host = insiders ? 'https://insiders.vscode.dev/redirect' : 'https://vscode.dev/redirect';
      // Encode the prefix and the raw URL separately so inner % are not double-encoded
      const prefix = encodeURIComponent(`${scheme}:${kind}/install?url=`);
      const raw = encodeURIComponent(rawUrl);
      return `${host}?url=${prefix}${raw}`;
    }
  • Helper function to generate the shield badge image URL for the install buttons.
    function makeInstallBadge(color: string, label: string) {
      // e.g., VS_Code-Install-0098FF
      return `https://img.shields.io/badge/${encodeURIComponent(label)}-Install-${color}?style=flat-square&logo=visualstudiocode&logoColor=white`;
    }
  • Zod input schema for the tool parameters: kind (enum of chat types) and url (validated URL).
    inputSchema: {
      kind: z.enum(["chat-instructions", "chat-prompt", "chat-mode"]).describe("Install kind"),
      url: z.string().url().describe("Raw GitHub URL or any public raw URL to the file."),
    }
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 tool 'generates' something, implying a read-only or creation operation, but does not clarify if this involves side effects, authentication needs, rate limits, or output format. For a tool with no annotations, this leaves significant behavioral gaps, as it doesn't describe what the generated buttons look like or how they are returned.

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 purpose without unnecessary details. It is front-loaded with the core action and resource, making it easy to parse. There is no wasted language, and every word contributes to understanding the tool's function, exemplifying optimal conciseness.

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 has no annotations and no output schema, the description is incomplete. It explains what the tool does but lacks details on behavioral aspects like side effects, authentication, or what the generated buttons entail. For a tool that likely produces visual or interactive elements, the absence of output information and behavioral context makes it insufficient for full agent understanding, especially compared to richer tool definitions.

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%, with both parameters ('kind' and 'url') well-documented in the schema. The description adds minimal value beyond the schema, as it only reiterates that the URL is for 'chat instructions, prompts, or chat modes', which aligns with the enum values in the schema. Since the schema does the heavy lifting, the baseline score of 3 is appropriate, as the description does not significantly enhance parameter understanding.

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's purpose: 'Generate VS Code install buttons for a raw URL to chat instructions, prompts, or chat modes.' It specifies the verb ('generate'), resource ('VS Code install buttons'), and target ('raw URL to chat instructions, prompts, or chat modes'), making the action clear. However, it does not explicitly differentiate from sibling tools like 'copilot_buttons_from_github', which likely serves a similar purpose but with different input sources, leaving room for improvement in sibling distinction.

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 mentions the input is a 'raw URL' but does not specify scenarios where this is preferred over sibling tools like 'copilot_buttons_from_github' or 'from_mcp_config'. Without explicit when-to-use or when-not-to-use instructions, the agent lacks context for tool selection, resulting in minimal guidance.

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/burkeholland/mcp-vsc-button-gen'

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