Skip to content

Latest commit

History

History
51 lines (39 loc) · 1.54 KB

File metadata and controls

51 lines (39 loc) · 1.54 KB

Xcode MCP Tools Reference

The following 20 tools become available when using xcodemcpwrapper with Xcode:

File Operations

ToolDescription
XcodeReadRead files from the project
XcodeWriteWrite files to the project
XcodeUpdateEdit files with str_replace-style patches
XcodeGlobFind files by pattern
XcodeGrepSearch file contents
XcodeLSList directory contents
XcodeMakeDirCreate directories
XcodeRMRemove files
XcodeMVMove/rename files

Build & Test

ToolDescription
BuildProjectBuild the Xcode project
GetBuildLogGet build output
RunAllTestsRun all tests
RunSomeTestsRun specific tests
GetTestListList available tests

Diagnostics & Navigation

ToolDescription
XcodeListNavigatorIssuesGet Xcode issues/errors
XcodeRefreshCodeIssuesInFileGet live diagnostics
XcodeListWindowsList open Xcode windows

Advanced Features

ToolDescription
ExecuteSnippetRun code in a REPL-like environment
RenderPreviewRender SwiftUI previews as images
DocumentationSearchSearch Apple docs and WWDC videos

Usage

Most tools require a tabIdentifier to specify which Xcode window to operate on. The typical flow:

  1. Call XcodeListWindows to discover open windows
  2. Get the tabIdentifier (e.g., windowtab1) and workspace path
  3. Use that identifier in subsequent tool calls