mcpinstall

package
v0.19.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 16, 2025 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package mcpinstall provides a public API for installing MCP server configurations for various AI coding assistants and editors.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Install

func Install(opts Options) error

Install installs an MCP server configuration for the specified client.

Required options:

  • ClientName: The name of the client to configure (e.g., "claude-code", "cursor", "windsurf")
  • ServerName: The name to register the MCP server as (e.g., "my-mcp-server")
  • Command: Path to the MCP server binary (e.g., "/usr/local/bin/my-server")
  • Args: Arguments to pass to the MCP server binary (e.g., []string{"serve", "--port", "8080"})

Optional fields:

  • CreateBackup: If true, creates a backup of the existing config file before modification
  • CustomConfigPath: Custom path to the config file (empty string uses default location)

Returns an error if the client is not supported, required options are missing, or installation fails.

Types

type ClientInfo

type ClientInfo = cmd.ClientInfo

ClientInfo contains information about a supported MCP client.

func SupportedClients

func SupportedClients() []ClientInfo

SupportedClients returns information about all supported MCP clients. Use this to get valid values for Options.ClientName.

type Options

type Options = cmd.InstallOptions

Options configures the MCP server installation behavior.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL