mcp.installers.config_manager ============================= .. py:module:: mcp.installers.config_manager .. autoapi-nested-parse:: MCP Configuration and Environment Management. Handles .env files, configuration templates, and secure credential storage. Classes ------- .. autoapisummary:: mcp.installers.config_manager.MCPConfigManager mcp.installers.config_manager.MCPEnvironmentConfig mcp.installers.config_manager.MCPServerPattern Module Contents --------------- .. py:class:: MCPConfigManager(config_dir: pathlib.Path | None = None) Manages MCP server configurations and environment files. .. py:method:: add_server_config(config: MCPEnvironmentConfig) -> bool Add a new server configuration. .. py:method:: export_claude_desktop_config(server_name: str) -> dict[str, Any] | None Export server config in Claude Desktop format. .. py:method:: get_config_summary() -> dict[str, Any] Get summary of all configurations. .. py:method:: get_pattern(pattern_name: str) -> MCPServerPattern | None Get a server pattern by name. .. py:method:: get_server_config(server_name: str) -> MCPEnvironmentConfig | None Get server configuration by name. .. py:method:: list_available_patterns() -> list[str] List all available server patterns. .. py:method:: list_configured_servers() -> list[str] List all configured servers. .. py:attribute:: config_dir .. py:attribute:: env_file .. py:attribute:: patterns_config .. py:attribute:: servers_config .. py:class:: MCPEnvironmentConfig(/, **data: Any) Bases: :py:obj:`pydantic.BaseModel` Environment configuration for MCP servers. .. py:attribute:: allowed_paths :type: list[str] :value: None .. py:attribute:: env_vars :type: dict[str, str] :value: None .. py:attribute:: package_name :type: str :value: None .. py:attribute:: port :type: int | None :value: None .. py:attribute:: requires_approval :type: bool :value: None .. py:attribute:: secure_vars :type: dict[str, pydantic.SecretStr] :value: None .. py:attribute:: server_name :type: str :value: None .. py:attribute:: startup_args :type: list[str] :value: None .. py:attribute:: transport_type :type: str :value: None .. py:attribute:: working_directory :type: str | None :value: None .. py:class:: MCPServerPattern Standard pattern for MCP server installation. .. py:attribute:: default_args :type: list[str] .. py:attribute:: env_template :type: dict[str, str] .. py:attribute:: install_command :type: str .. py:attribute:: package_pattern :type: str .. py:attribute:: pattern_name :type: str .. py:attribute:: security_level :type: str :value: 'safe' .. py:attribute:: startup_command :type: str .. py:attribute:: transport :type: str :value: 'stdio'