Supports building and testing for iOS platforms and simulators, facilitating the analysis of mobile application build outputs and diagnostics.
Facilitates structured access to macOS-native development tools, providing token-efficient analysis of build logs and compiler output for Apple ecosystem projects.
Enables execution and parsing of Swift Package Manager commands like build and test, with support for extracting test failures and code coverage data.
Provides tools for executing Xcode build actions and parsing raw output into structured formats, enabling AI assistants to extract errors, warnings, and test failures.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@xcsift-mcprun swift build and show me the errors"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
xcsift-mcp
An MCP (Model Context Protocol) server that wraps xcsift, enabling AI coding assistants to parse Xcode build output into structured, token-efficient formats.
Overview
xcsift-mcp provides AI coding assistants (like Claude, OpenCode, Cursor, etc.) with tools to:
Parse raw
xcodebuildorswift build/testoutput into structured JSON or TOON formatExecute build commands and get parsed results automatically
Extract errors, warnings, test failures, and linker errors with file/line information
Analyze code coverage from test runs
The output is optimized for token efficiency, with TOON format providing 30-60% fewer tokens compared to JSON.
Quick Start
Then configure your AI assistant to use the server (see Integration below).
Installation
Prerequisites
Python 3.10+
macOS (xcsift is macOS-only)
Install from source
Install with development dependencies
xcsift Binary
The server will automatically download the xcsift binary from GitHub releases on first run if it's not already installed. The binary is cached in ~/.local/share/xcsift-mcp/bin/.
Alternatively, you can install it manually:
Usage
Running the Server
Integration with AI Assistants
Claude Desktop
Add to your claude_desktop_config.json:
OpenCode
Cursor
Add to your MCP configuration in Cursor settings, or add to .cursor/mcp.json:
Available Tools
Parsing Tools
Tool | Description |
| Parse raw xcodebuild/swift output into JSON or TOON format |
| Extract only errors with file/line information |
| Extract only warnings with file/line/type |
| Extract failed tests with assertion messages |
| Get a quick summary with error/warning counts |
Build Execution Tools
Tool | Description |
| Run xcodebuild and parse output automatically |
| Run swift build for SPM projects |
| Run swift test with optional coverage |
| Run arbitrary build commands and parse output |
Tool Parameters
parse_xcodebuild_output
Parameter | Type | Default | Description |
| string | required | Raw xcodebuild/swift output (use |
|
|
| Output format |
| bool |
| Include detailed warnings list |
| bool |
| Include coverage data if available |
xcodebuild
Parameter | Type | Default | Description |
|
|
| Build action |
| string | none | Scheme to build |
| string | none | Path to .xcodeproj |
| string | none | Path to .xcworkspace |
| string | none | Destination (e.g., |
|
| none | Build configuration |
| bool |
| Enable coverage for tests |
|
|
| Output format |
| int |
| Timeout in seconds |
swift_build
Parameter | Type | Default | Description |
|
|
| Build configuration |
| string | none | Path to Swift package |
| string | none | Specific target to build |
|
|
| Output format |
| int |
| Timeout in seconds |
swift_test
Parameter | Type | Default | Description |
| string | none | Path to Swift package |
| string | none | Filter tests (e.g., |
| bool |
| Enable coverage collection |
| bool |
| Run tests in parallel |
|
|
| Output format |
| int |
| Timeout in seconds |
Example Usage
Parse existing build output
Run build and get parsed results
Run tests with coverage
Extract just the errors
Output Formats
JSON Format
Standard structured JSON output:
TOON Format (Token-Optimized)
30-60% fewer tokens than JSON:
When to use each format:
JSON: When you need to parse the output programmatically or integrate with other tools
TOON: When sending to an LLM to reduce token usage and API costs
Available Resources
Resource URI | Description |
| xcsift version and installation info |
| Example .xcsift.toml configuration |
| Documentation about output formats |
| Comprehensive help documentation |
Available Prompts
Prompt | Description | Arguments |
| Template for analyzing build failures |
|
| Template for fixing Swift/ObjC compiler errors |
|
| Template for improving test coverage |
|
| Template for debugging test failures |
|
| Template for fixing linker errors |
|
| Template for analyzing build performance |
|
Development
Running Tests
Running Tests with Coverage
Code Formatting
Project Structure
Architecture
Troubleshooting
xcsift not found
If xcsift cannot be downloaded automatically, install it manually:
Permission denied
Ensure the xcsift binary has execute permissions:
Build timeout
Increase the timeout parameter for long builds:
License
MIT License - see LICENSE for details.
Credits
xcsift - The Swift CLI tool that does the actual parsing
MCP Python SDK - Model Context Protocol implementation