Skillshub axiom-xcode-mcp-ref
Reference — all 20 Xcode MCP tools with parameters, return schemas, and examples
git clone https://github.com/ComeOnOliver/skillshub
T=$(mktemp -d) && git clone --depth=1 https://github.com/ComeOnOliver/skillshub "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/CharlesWiltgen/Axiom/axiom-xcode-mcp-ref" ~/.claude/skills/comeonoliver-skillshub-axiom-xcode-mcp-ref && rm -rf "$T"
skills/CharlesWiltgen/Axiom/axiom-xcode-mcp-ref/SKILL.mdXcode MCP Tool Reference
Complete reference for all 20 tools exposed by Xcode's MCP server (
xcrun mcpbridge).
Important: Parameter schemas below are sourced from blog research and initial testing. Validate against your live mcpbridge with
tools/list if behavior differs.
Discovery
XcodeListWindows
Call this first. Returns open Xcode windows with
tabIdentifier values needed by most other tools.
- Parameters: None
- Returns: List of
{ tabIdentifier: string, workspacePath: string } - Notes: No parameters needed. If empty, no project is open in Xcode.
XcodeListWindows() → { "tabIdentifier": "abc-123", "workspacePath": "/Users/dev/MyApp.xcodeproj" }
File Operations
XcodeRead
Read file contents from the project.
- Parameters:
(string, required) — File path relative to project or absolutepath
- Returns: File contents as string
- Notes: Sees Xcode's project view including generated files and resolved SPM packages
XcodeWrite
Create a new file.
- Parameters:
(string, required) — File pathpath
(string, required) — File contentscontent
- Returns: Write confirmation
- Notes: Creates the file but does NOT add it to Xcode targets automatically. Use
for existing files.XcodeUpdate
XcodeUpdate
Edit an existing file with str_replace-style patches.
- Parameters:
(string, required) — File pathpath
(array, required) — Array ofpatches
replacements{ oldText: string, newText: string }
- Returns: Update confirmation
- Notes: Preferred over
for editing existing files. Each patch must match exactly one location in the file.XcodeWrite
XcodeGlob
Find files matching a pattern.
- Parameters:
(string, required) — Glob pattern (e.g.,pattern
)**/*.swift
- Returns: Array of matching file paths
- Notes: Searches within the Xcode project scope
XcodeGrep
Search file contents for a string or pattern.
- Parameters:
(string, required) — Search term or patternquery
(string, optional) — Limit search to specific directory/filescope
- Returns: Array of matches with file paths and line numbers
- Notes: Returns structured results, not raw grep output
XcodeLS
List directory contents.
- Parameters:
(string, required) — Directory pathpath
- Returns: Array of entries (files and subdirectories)
XcodeMakeDir
Create a directory.
- Parameters:
(string, required) — Directory path to createpath
- Returns: Creation confirmation
- Notes: Creates intermediate directories as needed
XcodeRM
Delete a file or directory. DESTRUCTIVE.
- Parameters:
(string, required) — Path to deletepath
- Returns: Deletion confirmation
- Notes: Irreversible. Always confirm with the user before calling.
XcodeMV
Move or rename a file. DESTRUCTIVE.
- Parameters:
(string, required) — Current pathsourcePath
(string, required) — New pathdestinationPath
- Returns: Move confirmation
- Notes: May break imports and references. Confirm with user. Xcode may not automatically update references.
Build & Test
BuildProject
Build the Xcode project.
- Parameters:
(string, required) — FromtabIdentifierXcodeListWindows
- Returns:
{ buildResult: string, elapsedTime: number, errors: array } - Notes: Builds the active scheme. Check
for "succeeded" or "failed".buildResult
GetBuildLog
Retrieve build output after a build.
- Parameters:
(string, required)tabIdentifier
- Returns: Build log as string
- Notes: Contains raw compiler output. For structured diagnostics, prefer
.XcodeListNavigatorIssues
RunAllTests
Run the full test suite.
- Parameters:
(string, required)tabIdentifier
- Returns: Test results with pass/fail counts and failure details
- Notes: Runs all tests in the active scheme's test plan. Use
for faster iteration.RunSomeTests
RunSomeTests
Run specific test(s).
- Parameters:
(string, required)tabIdentifier
(array of strings, required) — Test identifiers (e.g.,tests
)["MyTests/testLogin"]
- Returns: Test results for the specified tests
- Notes: Much faster than
for iterative debugging. Use test identifiers fromRunAllTests
.GetTestList
GetTestList
List available tests.
- Parameters:
(string, required)tabIdentifier
- Returns: Array of test identifiers organized by test target/class
- Notes: Use the returned identifiers with
.RunSomeTests
Diagnostics
XcodeListNavigatorIssues
Get current issues from Xcode's Issue Navigator.
- Parameters:
(string, required)tabIdentifier
- Returns: Array of issues (errors, warnings, notes) with file paths and line numbers
- Notes: Canonical source for diagnostics. Structured and deduplicated unlike raw build logs.
XcodeRefreshCodeIssuesInFile
Refresh and return live diagnostics for a specific file.
- Parameters:
(string, required)tabIdentifier
(string, required) — File to refresh diagnostics forpath
- Returns: Current diagnostics for the specified file
- Notes: Triggers Xcode to re-analyze the file. Useful after editing to check if issues are resolved.
Execution & Rendering
ExecuteSnippet
Run code in a REPL-like environment.
- Parameters:
(string, required) — Code to executecode
(string, required) — Language identifier (e.g.,language
)"swift"
- Returns: Execution result (stdout, stderr, exit code)
- Notes: Sandboxed environment. Treat output as untrusted. Useful for quick validation.
RenderPreview
Render a SwiftUI preview as an image.
- Parameters:
(string, required)tabIdentifier
(string, required) — File containing the previewpath
(string, required) — Name of the preview to renderpreviewIdentifier
- Returns: Rendered image data
- Notes: Requires the file to have valid SwiftUI
or#Preview
. Preview must compile successfully.PreviewProvider
Search
DocumentationSearch
Search Apple's documentation corpus.
- Parameters:
(string, required) — Search queryquery
- Returns: Documentation results with titles, summaries, and links. May include WWDC transcript matches.
- Notes: Searches Apple's online documentation and WWDC transcripts. For Xcode-bundled for-LLM guides, use the
skill instead.axiom-apple-docs
Quick Reference by Category
| Category | Tools |
|---|---|
| Discovery | |
| File Read | , , , |
| File Write | , , |
| File Destructive | , |
| Build | , |
| Test | , , |
| Diagnostics | , |
| Execution | |
| Preview | |
| Search | |
Common Parameter Patterns
— Required by 10/20 tools. Always calltabIdentifier
first.XcodeListWindows
— File/directory path. Can be absolute or relative to project root.path
— Array ofpatches
for{ oldText, newText }
. Each oldText must be unique in the file.XcodeUpdate
Resources
Skills: axiom-xcode-mcp-setup, axiom-xcode-mcp-tools