mcp.downloader.legacy_coreΒΆ
General MCP Server Downloader - A flexible, configuration-driven approach.
This script provides a general, extensible system for downloading and configuring MCP servers from various sources using configurable installation strategies.
Key features: - Plugin architecture for different installation methods - Configuration-driven patterns and templates - Support for multiple server registries and sources - Flexible metadata handling - Batch processing with retry logic - Progress tracking and logging
AttributesΒΆ
ClassesΒΆ
Installer for Docker-based MCP servers. |
|
General MCP Server Downloader with configurable patterns and. |
|
Installer for Git-based MCP servers. |
|
Supported installation methods. |
|
Abstract base class for MCP installers. |
|
Installer for NPM-based MCP servers. |
|
Installer for Python/pip-based MCP servers. |
|
Configuration for a specific MCP server. |
|
Template for MCP server configuration. |
FunctionsΒΆ
|
Main function for CLI usage. |
Module ContentsΒΆ
- class mcp.downloader.legacy_core.DockerInstallerΒΆ
Bases:
MCPInstaller
Installer for Docker-based MCP servers.
- async can_handle(server_config: ServerConfig, template: ServerTemplate) bool ΒΆ
Can Handle.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async install(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) dict[str, Any] ΒΆ
Install.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async verify(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) bool ΒΆ
Verify.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- class mcp.downloader.legacy_core.GeneralMCPDownloader(config_file: str | None = None, install_dir: str | None = None)ΒΆ
General MCP Server Downloader with configurable patterns and. installers.
- async auto_discover_and_download(limit: int | None = None) dict[str, Any] ΒΆ
Auto-discover servers from registries and download them.
- create_default_config()ΒΆ
Create a default configuration file.
- async discover_servers_from_registry(registry_url: str) list[dict[str, Any]] ΒΆ
Discover MCP servers from a registry or documentation source.
- async download_servers(server_names: list[str] | None = None, categories: list[str] | None = None, max_concurrent: int = 5) dict[str, Any] ΒΆ
Download and install MCP servers.
- load_config()ΒΆ
Load configuration from file.
- config_file = 'mcp_downloader_config.yaml'ΒΆ
- install_dirΒΆ
- installers: list[MCPInstaller]ΒΆ
- servers: list[ServerConfig] = []ΒΆ
- templates: dict[str, ServerTemplate]ΒΆ
- class mcp.downloader.legacy_core.GitInstallerΒΆ
Bases:
MCPInstaller
Installer for Git-based MCP servers.
- async can_handle(server_config: ServerConfig, template: ServerTemplate) bool ΒΆ
Can Handle.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async install(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) dict[str, Any] ΒΆ
Install.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async verify(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) bool ΒΆ
Verify.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- class mcp.downloader.legacy_core.InstallationMethod(*args, **kwds)ΒΆ
Bases:
enum.Enum
Supported installation methods.
- BINARY = 'binary'ΒΆ
- CURL = 'curl'ΒΆ
- DOCKER = 'docker'ΒΆ
- GIT = 'git'ΒΆ
- MANUAL = 'manual'ΒΆ
- NPM = 'npm'ΒΆ
- PIP = 'pip'ΒΆ
- SCRIPT = 'script'ΒΆ
- class mcp.downloader.legacy_core.MCPInstallerΒΆ
Bases:
abc.ABC
Abstract base class for MCP installers.
- abstractmethod can_handle(server_config: ServerConfig, template: ServerTemplate) bool ΒΆ
- Async:
Check if this installer can handle the given configuration.
- abstractmethod install(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) dict[str, Any] ΒΆ
- Async:
Install the MCP server.
- abstractmethod verify(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) bool ΒΆ
- Async:
Verify the installation was successful.
- class mcp.downloader.legacy_core.NPMInstallerΒΆ
Bases:
MCPInstaller
Installer for NPM-based MCP servers.
- async can_handle(server_config: ServerConfig, template: ServerTemplate) bool ΒΆ
Can Handle.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async install(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) dict[str, Any] ΒΆ
Install.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async verify(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) bool ΒΆ
Verify.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- class mcp.downloader.legacy_core.PipInstallerΒΆ
Bases:
MCPInstaller
Installer for Python/pip-based MCP servers.
- async can_handle(server_config: ServerConfig, template: ServerTemplate) bool ΒΆ
Can Handle.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async install(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) dict[str, Any] ΒΆ
Install.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- async verify(server_config: ServerConfig, template: ServerTemplate, install_dir: pathlib.Path) bool ΒΆ
Verify.
- Parameters:
server_config β [TODO: Add description]
template β [TODO: Add description]
install_dir β [TODO: Add description]
- Returns:
Add return description]
- Return type:
[TODO
- class mcp.downloader.legacy_core.ServerConfigΒΆ
Configuration for a specific MCP server.
- class mcp.downloader.legacy_core.ServerTemplateΒΆ
Template for MCP server configuration.
- installation_method: InstallationMethodΒΆ
- async mcp.downloader.legacy_core.main()ΒΆ
Main function for CLI usage.
- mcp.downloader.legacy_core.aiohttp = NoneΒΆ
- mcp.downloader.legacy_core.loggerΒΆ
- mcp.downloader.legacy_core.yaml = NoneΒΆ