Introduce ClawdCursorHost (host IPC) and macOS native helper enhancements#48
Open
Introduce ClawdCursorHost (host IPC) and macOS native helper enhancements#48
Conversation
AmrDab
added a commit
that referenced
this pull request
Apr 8, 2026
Cherry-picked from PR #48 (Codex): - doctor.ts: Direct users to enable 'ClawdCursor' instead of 'Terminal/Node' - readiness.ts: Same permission message improvements - Updated to 'Screen & System Audio Recording' (macOS Sequoia naming) PR #48 is redundant (core functionality merged via PR #47) and should be closed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
ClawdCursor.app) and provide a long-lived host process to own IPC and permission-sensitive operations.Description
ClawdCursorHostwith a small HTTP IPC server (127.0.0.1:<port>) and token auth, and register it inPackage.swiftand the app bundle (Info.plist).native/build.sh) to includeClawdCursorHostin theClawdCursor.appbundle and change the default run hint toopen ClawdCursor.app.ClawdCursorHelper) with new JSON-RPC methods:moveMouse,dragMouse, andcaptureScreen(PNG base64 encoding), and add required imports (ImageIO,UniformTypeIdentifiers).Sources/ClawdCursorHost/main.swiftimplementing the host listener, health/status endpoints, and proxying JSON-RPCPOST /rpctoclawdcursor-helperwhen authorized.src/native-helper.ts) to prefer communicating with the host IPC (/health,/status,/rpc), add utility functions (isHostRunning,ensureHostAppRunning,stopHostApp, token management), and provide fallback behavior controlled viaCLAWDCURSOR_ALLOW_MAC_HELPER_FALLBACK.src/native-desktop.tsnow uses the native helper for captures, mouse moves/drags, typing and key presses on macOS when available;src/index.ts,src/doctor.ts, andsrc/readiness.tsupdated to ensure the host is running and to referenceClawdCursorin user-facing messages.permission-checkbinary.native/README.mdto document the newClawdCursorHostIPC endpoints and workflow.Testing
./native/build.shwhich runsswift build -c release) and confirmedClawdCursor.appartifacts were produced successfully.npm run build) to ensure updated imports and types pass compilation.ClawdCursorHostand verifyingGET /healthandGET /statusreturn expected JSON (local smoke tests succeeded).Codex Task