Skip to content

OPE-273: Small follow-ups from OPE-272 API fixes #547

Closed

Description

@ivanfenenko

Minor findings from reviewing the OPE-272 fixes on main @ 915095b (opencode-mobile/opencode-mobile#346, opencode-mobile/opencode-mobile#347, opencode-mobile/opencode-mobile#348). They apply to both Android and iOS.

  • Typed pairing code with a custom username gives a 401. The typed one-time-code path keeps whatever username is in the connection form, and that field is hidden in code mode. The server accepts the redeemed token only for user opencode, so a leftover custom username fails. Scanned QR codes are unaffected. Fix: force the username to opencode when pairing by code (the code mode in ConnectionSetupViewModel, Kotlin + Swift).
  • Servers on v2.0.0 to v2.0.3 are no longer detected. Those versions only serve /api/health, which the app no longer probes now that it uses /api/info. v2.0.4 and v2.0.5 serve neither route, so they weren't detected before either. Decide whether to keep /api/health as a fallback probe or document a minimum server version (ServerProtocolDetector / ServerProtocolClassifier).
  • Dead code cleanup. replyToQuestionV2 and rejectQuestionV2 (/api/session/{id}/question/*, not in the v2 spec) are still the fallback for ids without the frm_ prefix, but in practice they can't be reached. Remove them. Also update Android's bodyOnSuccess comment, which still mentions the removed question-to-form fallback.

Imported from Linear OPE-273. Linear status: Done. Priority: Low. Created 2026-10-07. Completed 2026-10-07.
Related: OPE-272, OPE-275.

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

Metadata

Metadata

Assignees

Labels

priority: low

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions