xcode-mcp-server
v1.0.3An MCP server for Xcode integration, enabling AI assistants to interact with Xcode projects
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
set_projects_base_dir
Sets the base directory where your Xcode projects are stored.
| Parameter | Type | Description |
|---|---|---|
baseDir * | string | Absolute path to the directory containing your Xcode projects. |
set_project_path
Sets the active Xcode project by specifying the path to its .xcodeproj directory.
| Parameter | Type | Description |
|---|---|---|
projectPath * | string | Path to the .xcodeproj directory for the desired project. |
get_active_project
Retrieves detailed information about the currently active Xcode project.
read_file
Reads the contents of a file within the active Xcode project.
| Parameter | Type | Description |
|---|---|---|
filePath * | string | Relative or absolute path to the file within the active project. |
write_file
Writes or updates the content of a file in the active Xcode project.
| Parameter | Type | Description |
|---|---|---|
content * | string | The content to be written to the file. |
filePath * | string | Relative or absolute path to the file to update or create. |
createIfMissing | boolean | If true, creates the file if it doesn't exist. |
list_project_files
Lists all files within an Xcode project.
| Parameter | Type | Description |
|---|---|---|
projectPath * | string | Path to the .xcodeproj directory of the project. |
fileType | string | Optional file extension filter. |
analyze_file
Analyzes a source file for potential issues using Xcode's static analyzer.
| Parameter | Type | Description |
|---|---|---|
filePath * | string | Path to the source file to analyze. |
build_project
Builds the active Xcode project using the specified configuration and scheme.
| Parameter | Type | Description |
|---|---|---|
configuration * | string | Build configuration to use (e.g., 'Debug' or 'Release'). |
scheme * | string | Name of the build scheme to be built. Must be one of the schemes available in the project. |
run_tests
Executes tests for the active Xcode project.
| Parameter | Type | Description |
|---|---|---|
testPlan | string | Optional name of the test plan to run. |
run_xcrun
Executes a specified Xcode tool via 'xcrun'.
| Parameter | Type | Description |
|---|---|---|
tool * | string | Name of the Xcode tool to execute. |
arguments | string | Optional additional arguments to pass to the specified tool. |
list_simulators
Lists all available iOS simulators with their details by invoking 'xcrun simctl list --json'.
boot_simulator
Boots an iOS simulator identified by its UDID.
| Parameter | Type | Description |
|---|---|---|
udid * | string | The UDID of the simulator to boot. |
shutdown_simulator
Shuts down an active iOS simulator using its UDID.
| Parameter | Type | Description |
|---|---|---|
udid * | string | The UDID of the simulator to shutdown. |
compile_asset_catalog
Compiles an asset catalog using 'actool'.
| Parameter | Type | Description |
|---|---|---|
catalogPath * | string | Path to the asset catalog. |
outputDir * | string | Directory where the compiled assets should be saved. |
run_lldb
Launches the LLDB debugger with custom arguments.
| Parameter | Type | Description |
|---|---|---|
lldbArgs | string | Optional LLDB arguments. |
trace_app
Captures a performance trace of an application using 'xctrace'.
| Parameter | Type | Description |
|---|---|---|
appPath * | string | Path to the application binary to trace. |
duration | number | Duration (in seconds) for the trace. |
swift_package_update
Updates the dependencies of your Swift project using Swift Package Manager by invoking 'swift package update'.
list_directory
Lists the contents of a directory, showing both files and subdirectories.
| Parameter | Type | Description |
|---|---|---|
path * | string | Path to the directory to list. |