Skip to content

feat(desktop): add LAN mobile remote control - #41392

Draft
AlexZander85 wants to merge 35 commits into
anomalyco:devfrom
AlexZander85:remote-control
Draft

feat(desktop): add LAN mobile remote control#41392
AlexZander85 wants to merge 35 commits into
anomalyco:devfrom
AlexZander85:remote-control

Conversation

@AlexZander85

@AlexZander85 AlexZander85 commented Aug 9, 2026

Copy link
Copy Markdown

Issue for this PR

Related to #10288

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Adds LAN-only remote control for an existing OpenCode Desktop session.

From the session header, the user can open Remote Control, scan a QR code with a phone on the same local network, and control that session through a session-scoped mobile interface.

The remote interface supports:

  • viewing visible session messages and status
  • sending text prompts
  • aborting the current run
  • answering permission requests
  • answering questions

The implementation intentionally does not expose the full sidecar API, terminal access, filesystem access, or Internet/relay access.

Pairing uses a short-lived one-time ticket which is exchanged for a revocable session-scoped grant. The Desktop LAN gateway only proxies /remote/*.

This is a draft PR mainly to get feedback on whether this narrower LAN-only approach fits the project direction.

How did you verify your code works?

Added targeted unit/integration coverage for pairing, session-scoped authorization, cross-session rejection, bootstrap/event filtering, text-only prompts, revoke/session deletion, pairing lifecycle races, LAN address changes, and gateway boundaries.

Also ran a browser-level Chromium/Playwright smoke test of the production mobile UI covering pairing, permission reply, question reply, sending a prompt, live refresh, and stop/abort.

The browser flow completed without page errors. Physical phone-to-Desktop LAN testing and upstream CI are still pending.

Screenshots / recordings

remote-control-demo

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions

github-actions Bot commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Hey! Your PR title Remote control doesn't follow conventional commit format.

Please update it to start with one of:

  • feat: or feat(scope): new feature
  • fix: or fix(scope): bug fix
  • docs: or docs(scope): documentation changes
  • chore: or chore(scope): maintenance tasks
  • refactor: or refactor(scope): code refactoring
  • test: or test(scope): adding or updating tests

Where scope is the package name (e.g., app, desktop, opencode).

See CONTRIBUTING.md for details.

@github-actions github-actions Bot added needs:title needs:compliance This means the issue will auto-close after 2 hours. labels Aug 9, 2026
@AlexZander85 AlexZander85 changed the title Remote control feat(desktop): add LAN mobile remote control Aug 9, 2026
@AlexZander85
AlexZander85 marked this pull request as draft August 9, 2026 10:35
@github-actions github-actions Bot removed needs:title needs:compliance This means the issue will auto-close after 2 hours. labels Aug 9, 2026
@github-actions

github-actions Bot commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant