You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
V2: Add service QR pairing and connection-details endpoint #35943
Add a first-class V2 pairing flow for connecting OpenCode clients such as OpenMobile to an existing service:
opencode2 service qr renders a scannable QR code for the current service.
An authenticated server endpoint returns the canonical connection/pairing details so already-connected clients (including the TUI) can render the same QR or deep link.
This replaces helper scripts that discover service details and construct QR payloads outside OpenCode.
Proposed behavior
The CLI obtains all connection details through the service/CLI APIs rather than reading or manipulating OpenCode state files directly.
The QR encodes a versioned OpenMobile-compatible deep link that can add/open the server.
The server exposes a typed, documented response containing the canonical pairing payload and structured connection details needed by clients.
Connected clients can use the endpoint to show a QR without reconstructing service configuration independently.
Authentication secrets are returned only to an already-authenticated caller and must not appear in logs or diagnostics.
The schema can represent the currently reachable address (including Tailscale) and later accommodate OpenTunnel without changing client-specific parsing logic.
Deliverables
opencode2 service qr
Authenticated server endpoint and OpenAPI schema
Shared/versioned deep-link or pairing schema
Tests for CLI rendering, endpoint authorization, and payload round-tripping
Send the finalized schema to the OpenMobile client owner for integration
Open questions
Should the endpoint return only structured data/deep-link text, or also a rendered QR representation?
How should a service select or advertise among localhost, LAN, Tailscale, and future OpenTunnel addresses?
Should pairing credentials be reusable service credentials or short-lived/revocable tokens?
Cross-reference: #36116 defines plugin-contributed server metadata that QR/pairing and connection-details clients may consume. These should be designed together.
Activity
opencode-agent commentedon Jul 10, 2026
Cross-reference: #36116 defines plugin-contributed server metadata that QR/pairing and connection-details clients may consume. These should be designed together.