How I built a Mac app that hands your screen to Claude Code, Codex and Cursor
Accessibility APIs, on-device OCR, headless Claude Code and Codex, usage read from local logs, and a 4.5 MB native Swift app. tags: macos, swift, ai, productivity I use AI agents all day, and the slow part was never the model. It was the hand-off: copy the error, switch to the agent, paste, explain which project and file, repeat for the next agent. So I built Beckon : press ⌥⇧Space in any Mac…
Beckon is a Mac app that integrates Claude Code, Codex, and Cursor to provide AI-powered assistance directly from within any Mac application. The app captures the content visible on the user's screen using Accessibility APIs, OCR, and screen capture technology, then sends the information to the selected AI agent. The agent processes the information and returns the response, which is displayed in Beckon's interface.
To ensure security and prevent code injection, Beckon handles the user's prompt by writing it to a file and running the agent from that file instead of embedding it directly into the command. This approach eliminates the risk of remote code execution. The app also takes care to remove any sensitive information from the user's prompt, such as URLs or executable commands, before sending it to the agent.
Beckon supports various AI agents, including Claude Code, Codex, Cursor, and others, by adapting to each agent's specific requirements. For headless agents, Beckon runs the agent in a login shell to ensure proper environment variables and PATH settings. The agent's output is streamed in real-time and displayed in the app's interface as the user sees fit.
Throughout its operation, Beckon keeps track of each agent's usage, including token counts, limit information, and error messages, without relying on any external server. The app logs this information locally to help users monitor their AI agent usage and manage costs effectively.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.