uicheck_apple

Source: README

Install

Swift Package: https://github.com/uicheck/uicheck, product UICheckApple

Apple native runtime client for UI Check. It connects iOS, macOS, tvOS, or visionOS apps to @uicheck/mcp over WebSocket so AI agents can request screenshots and inspect the live UIKit/AppKit view tree.

Install

Add this repository as a Swift Package dependency and select the UICheckApple product:

https://github.com/uicheck/uicheck

Package path:

packages/apple

Start the MCP server separately:

npx @uicheck/mcp

Usage

Install the client near app startup:

import UICheckApple
 
let client = initUiCheck(
  UiCheckAppleOptions(
    socket: UiCheckAppleSocketOptions(
      clientId: "ios-demo"
    ),
    screenshot: { params in
      UiCheckAppleScreenshotResult(
        width: 390,
        height: 844,
        mimeType: "image/png",
        base64: captureAppAsBase64Png()
      )
    }
  )
)

Dispose when no longer needed:

client.close()

Options

OptionTypeDefaultDescription
socket.urlString-@uicheck/mcp WebSocket URL
socket.clientIdString-Optional stable client id
socket.reconnectMsInt1000Reconnect interval
screenshotfunction-Optional screenshot function for capture_page, capture_element, and compare_screenshot, returning PNG base64