Atlas / MCP servers / lapfelix / Xcode

XcodeBLOCK

mcp/lapfelix/xcode-4

MCP server for Xcode that wraps its AppleScript interface & uses XCLogParser to return clear build results

Verdict
BLOCK
Grade
D
Trust score
69 /100
Exposed tools
26 20r · 6w · 0d
Transport
sse · stdio
License
Apache-2.0
Stars
59
01

Overview

From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.

Using with Apple's Official Xcode MCP: Apple now provides an official Xcode MCP server. XcodeMCP can run alongside it in sidekick mode (--sidekick-only), providing complementary tools like project management and XCResult analysis. In a future version, XcodeMCP will transition to sidekick-only mode by default. See configuration below.

[](https://www.npmjs.com/package/xcodemcp) [](https://github.com/lapfelix/XcodeMCP/actions/workflows/test.yml)

Model Context Protocol (MCP) server that controls Xcode directly through JavaScript for Automation (JXA). Available as both an MCP server and a standalone CLI.

What it does

  • Controls Xcode directly through JavaScript for Automation (not xcodebuild CLI)
  • Opens projects, builds, runs, tests, and debugs from within Xcode
  • Parses build logs with precise error locations using XCLogParser
  • Provides comprehensive environment validation and health checks
  • Supports graceful degradation when optional dependencies are missing
  • NEW: Includes a full-featured CLI with 100% MCP server feature parity

Requirements

  • macOS with Xcode installed
  • Node.js 18+
  • XCLogParser (recommended): brew install xclogparser

Usage

XcodeMCP can be used in two ways:

  1. MCP Server: Integrate with Claude Desktop, VS Code, or other MCP clients
  2. CLI Tool: Run commands directly from the terminal with xcodecontrol

Quick Install

[](https://insiders.vscode.dev/redirect/mcp/install?name=xcodemcp&config=%7B%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22xcodemc

Read from source at commit c8f102c21707OBSERVED · 2026-10-08
Advertisement
02

Connect

Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control.

claude-code
claude mcp add xcodemcp -- npx -y [email protected]
claude-desktop
{
  "mcpServers": {
    "xcodemcp": {
      "command": "npx",
      "args": [
        "-y",
        "[email protected]"
      ]
    }
  }
}
03

Exposed tools (26)

20 read · 6 write · 0 destructive.

ToolRiskDescription
find_xcresultsreadFind all XCResult files for a specific project with timestamps and file information
xcode_buildreadBuild a specific Xcode project or workspace with the specified scheme. If destination is not provided, uses the currently active destination.
xcode_build_and_runwriteBuild and run a specific project with the specified scheme
xcode_cleanreadClean the build directory for a specific project
xcode_close_projectreadClose the currently active Xcode project or workspace (automatically stops any running actions first)
xcode_debugwriteStart debugging session for a specific project
xcode_get_projectsreadGet list of projects in a specific workspace
xcode_get_run_destinationswriteGet list of available run destinations for a specific project
xcode_get_schemesreadGet list of available schemes for a specific project
xcode_get_test_targetsreadGet information about test targets in a project, including names and identifiers
xcode_get_workspace_inforeadGet information about a specific workspace
xcode_health_checkreadPerform a comprehensive health check of the XcodeMCP environment and configuration
xcode_open_filereadOpen a file in Xcode
xcode_open_projectreadOpen an Xcode project or workspace
xcode_refresh_projectreadRefresh/reload an Xcode project by closing and reopening it to pick up external changes like modified .xctestplan files
xcode_set_active_schemewriteSet the active scheme for a specific project
xcode_stopwriteStop the current scheme action
xcode_testwriteRun tests for a specific project
xcresult_browsereadBrowse XCResult files - list all tests or show details for a specific test. Returns comprehensive test results including pass/fail status, failure details, and browsing instructions. Large console output (>20 lines or >2KB) is automatically saved to a temporary file.
xcresult_browser_get_consolereadGet console output and test activities for a specific test in an XCResult file. Large output (>20 lines or >2KB) is automatically saved to a temporary file.
xcresult_export_attachmentreadExport a specific attachment by index - can convert App UI hierarchy attachments to JSON
xcresult_get_screenshotreadGet screenshot from a failed test at specific timestamp - extracts frame from video attachment using ffmpeg
xcresult_get_ui_elementreadGet full details of a specific UI element by index from a previously exported UI hierarchy JSON file
xcresult_get_ui_hierarchyreadGet UI hierarchy attachment from test. Returns raw accessibility tree (best for AI), slim AI-readable JSON (default), or full JSON.
xcresult_list_attachmentsreadList all attachments for a specific test - shows attachment names, types, and indices for export
xcresult_summaryreadGet a quick summary of test results from an XCResult file
04

Trust audit

BLOCKgrade D · trust 69/100 Do not install this without reading the findings. The audit found something that could harm you or your machine.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codeFAIL
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
declared (2 observation(s))
Network
none-observed
Shell
none-observed
Dependencies
not all pinned
Secrets in source
none-found

Findings (15)

HIGHPrivilege escalation / persistence · priv.escalate · CWE-269, CWE-250
dist/tools/ProjectTools.js:59
text: '❌ No Xcode installation found\n\n💡 To fix this:\n• Install Xcode from the Mac App Store\n• Run: sudo xcode-select -s /Applications/Xcode.app/Contents/Developer'
Why it matters. asks for elevated privileges
HIGHPrivilege escalation / persistence · priv.escalate · CWE-269, CWE-250
src/tools/ProjectTools.ts:65
text: '❌ No Xcode installation found\n\n💡 To fix this:\n• Install Xcode from the Mac App Store\n• Run: sudo xcode-select -s /Applications/Xcode.app/Contents/Developer'
Why it matters. asks for elevated privileges
LOWCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
__tests__/functional.test.js:64
new Function(script);
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
LOWCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
__tests__/functional.vitest.test.js:64
new Function(script);
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
__tests__/environment-validator.vitest.test.ts:41
return createMockProcess('/usr/local/bin/xclogparser', '', 0);
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
__tests__/environment-validator.vitest.test.ts:59
expect(result.metadata?.path).toBe('/usr/local/bin/xclogparser');
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
__tests__/environment-validator.vitest.test.ts:109
return createMockProcess('/usr/local/bin/xclogparser', '', 0);
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
__tests__/environment-validator.vitest.test.ts:143
'/usr/local/bin/xclogparser',
LOWFilesystem / path · fs.system_paths · CWE-22, CWE-59
__tests__/environment-validator.vitest.test.ts:177
const foundPath = '/usr/local/bin/xclogparser';
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
__tests__/tools/ProjectTools.vitest.test.ts:31
import { ProjectTools } from '../../src/tools/ProjectTools.js';
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
dist/utils/EnvironmentValidator.js:491
const packageJsonPath = path.join(__dirname, '../../package.json');
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
src/utils/EnvironmentValidator.ts:524
const packageJsonPath = path.join(__dirname, '../../package.json');
LOWPrivilege escalation / persistence · priv.escalate · CWE-269, CWE-250
.github/workflows/publish-mcp.yml:57
sudo mv mcp-publisher /usr/local/bin/
Why it matters. asks for elevated privileges
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
package.json
@modelcontextprotocol/sdk, commander, eventsource, node-fetch, @types/node, @vitest/coverage-v8, @vitest/ui, execa
Why it matters. 11 dependency range(s) float
Fix. pin exact versions or ship a lockfile
INFOPrompt injection · scope.undeclared_system · CWE-94, CWE-1427
<declared scope>
system use found in code, not declared in the description
Why it matters. the description does not admit a capability the code has
Fix. declare system use in the description, or remove it

Gates applied: no_behavioural_pass.

Audited 2026-10-08 · audit v0.4.1 · source sha c8f102c21707full audit observations/trust-audit/mcp-server/lapfelix__xcode-4.json · Report an issue / request a re-scan
05

Audit history

Every audit this server has had. A grade with a past is a grade somebody is still checking.

DateSourceVerdictGradeScoreChange
2026-10-08c8f102c21707BLOCKD69first audit
06

Questions

What is the Xcode MCP server?

MCP server for Xcode that wraps its AppleScript interface & uses XCLogParser to return clear build results

What tools does Xcode expose?

26 in total: 20 read-only, 6 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.

Is Xcode safe to connect to an agent?

No — not without reading the findings first. The audit graded it D (69/100) and found 2 critical or high issues in the source. Each one is listed on this page with the file and line it is on.

What credentials does Xcode need?

No credential environment variables were found in its source, so it appears to need none.

How does Xcode run?

It speaks sse and stdio, so it runs as a local process your client starts. It is published on npm as xcodemcp at 2.1.4.

How current is this page?

The grade is for one exact copy of the source (c8f102c21707), read on 2026-10-08. The repository is watched and re-audited when it changes.

Advertisement