Extends Cap’s deeplinks support for recording control and adds a complete Raycast extension to manage recordings from the command bar.
cap://recording/start - Start a new recordingcap://recording/stop - Stop current recordingcap://recording/pause - Pause recordingcap://recording/resume - Resume recordingcap://recording/switch-microphone?id={id} - Switch microphonecap://recording/switch-camera?id={id} - Switch cameranpm install
npm run dev
open "cap://recording/start"
Closes #1540
/claim #1540
This PR extends Cap’s deeplink support with 4 new recording control actions (pause, resume, switch camera, switch microphone) and adds a Raycast extension to trigger these actions.
Backend Changes (Rust)
DeepLinkAction enum with PauseRecording, ResumeRecording, SwitchCamera, and SwitchMicrophone variantsFrontend Changes (Raycast Extension)
generateDeeplink() utility to build deeplink URLsCritical Issues Found
"ACTION_HERE" instead of actual action names (pause_recording, resume_recording, etc.)generateDeeplink() function has flawed logic that only handles switch_camera and switch_microphone, leaving other actions with empty parameter objectsstart-recording.tsx is missing required parameters (capture_mode, camera, mic_label, capture_system_audio, mode)switch-camera.tsx and switch-microphone.tsx need device/microphone selection UI - currently pass placeholder valuesImpact All Raycast commands will fail at runtime because the generated deeplink URLs won’t match the Rust enum variants. The backend implementation is solid, but the frontend is incomplete.
"ACTION_HERE" instead of actual action names, and the generateDeeplink() utility has broken logic. This means none of the advertised Raycast functionality will work.packages/raycast-extension/src/utils/deeplink.ts and all 6 command files in packages/raycast-extension/src/commands/| Filename | Overview |
|---|---|
| apps/desktop/src-tauri/src/deeplink_actions.rs | Added 4 new deeplink action variants (pause, resume, switch camera/mic) with proper implementations |
| packages/raycast-extension/src/commands/pause-recording.tsx | Contains placeholder “ACTION_HERE” instead of actual action name - will fail at runtime |
| packages/raycast-extension/src/commands/resume-recording.tsx | Contains placeholder “ACTION_HERE” instead of actual action name - will fail at runtime |
| packages/raycast-extension/src/commands/start-recording.tsx | Contains placeholder “ACTION_HERE” and missing required parameters - will fail at runtime |
| packages/raycast-extension/src/commands/stop-recording.tsx | Contains placeholder “ACTION_HERE” instead of actual action name - will fail at runtime |
| packages/raycast-extension/src/commands/switch-camera.tsx | Contains placeholder “ACTION_HERE” and needs device selection UI - will fail at runtime |
| packages/raycast-extension/src/commands/switch-microphone.tsx | Contains placeholder “ACTION_HERE” and needs microphone selection UI - will fail at runtime |
| packages/raycast-extension/src/utils/deeplink.ts | Logic error: only handles switch_camera/switch_microphone, all other actions generate empty objects |
sequenceDiagram
participant User
participant Raycast as Raycast Extension
participant DeeplinkUtil as generateDeeplink()
participant Cap as Cap Desktop App
participant DeeplinkHandler as deeplink_actions.rs
participant Recording as Recording Module
User->>Raycast: Select command (e.g., "Pause Recording")
Raycast->>DeeplinkUtil: generateDeeplink("pause_recording")
DeeplinkUtil->>DeeplinkUtil: Build JSON: {"pause_recording": {}}
DeeplinkUtil->>DeeplinkUtil: Create URL: cap://action?value=...
DeeplinkUtil-->>Raycast: Return deeplink URL
Raycast->>Cap: Open deeplink URL
Cap->>DeeplinkHandler: handle(urls)
DeeplinkHandler->>DeeplinkHandler: Parse URL query param "value"
DeeplinkHandler->>DeeplinkHandler: Deserialize JSON to DeepLinkAction
DeeplinkHandler->>Recording: Execute action (e.g., pause_recording)
Recording-->>DeeplinkHandler: Result
DeeplinkHandler-->>Cap: Success/Error
Cap-->>Raycast: OS-level callback (success)
Raycast->>User: Show toast notification
(2/5) Greptile learns from your feedback when you react with thumbs up/down!
andynewtw
@andynewtw
Cap
@CapSoftware
Abhishek Verma
@w3Abhishek