Command Line Interface (CLI)¶
Configuration tool for setting up the JamfMCP server with AI platforms.
Overview¶
This CLI helps users configure JamfMCP to work with various AI platforms like Claude Desktop, Cursor, and others. It handles two installation modes:
PyPI Mode (default): For users who installed JamfMCP from PyPI
Development Mode (
--dev): For developers working on JamfMCP source code
Both modes configure the MCP server to run locally on the user’s machine.
The difference is how the server is invoked (uvx vs uv run).
Standalone functions¶
- format_err(exc: Exception) None[source]¶
Format and display an error message to stderr.
- Parameters:
exc (Exception) – The exception to format and display
- Return type:
None
- async validate_jamf_connection(url: str, credentials: dict[str, str]) bool[source]¶
Validate connection to Jamf Pro server.
- check_uv_installed() bool[source]¶
Check if uv is installed.
- Returns:
True if uv is installed
- Return type:
- show_next_steps(platform: str, workspace: Path | None) None[source]¶
Display next steps after successful configuration.
- Parameters:
platform (str) – The AI platform that was configured
workspace (Path | None) – Whether a workspace was specified (for Cursor, Gemini)
- Returns:
None
- Return type:
None
- get_project_paths() Path[source]¶
Get the project root path for development mode.
- Returns:
Path to the project root directory
- Return type:
Path
- get_config_path(platform: str, workspace: Path | None = None) Path[source]¶
Get the configuration file path for the specified platform.
- Parameters:
platform (str) – The AI platform (claude-desktop, cursor, claude-code, gemini-cli)
workspace (Path | None) – Optional workspace directory for project-specific configurations
- Returns:
Path to the platform’s configuration file
- Return type:
Path
- build_config(dev: bool, credentials: dict) dict[str, Any][source]¶
Build the MCP server configuration.
- save_mcp_config(config: dict[str, Any], platform: str, workspace: Path | None) bool[source]¶
Save MCP configuration, merging with existing config if present.
Tip
For a list of all options to pass to the CLI, see the CLI setup guide