Skip to content

FrameOS Cloud 1/4: device-flow linking of backends and frames#263

Open
mariusandra wants to merge 2 commits into
mainfrom
cloud-link
Open

FrameOS Cloud 1/4: device-flow linking of backends and frames#263
mariusandra wants to merge 2 commits into
mainfrom
cloud-link

Conversation

@mariusandra

@mariusandra mariusandra commented Jul 18, 2026

Copy link
Copy Markdown
Collaborator

Summary

First of a four-PR stack splitting up the FrameOS Cloud work (#257):

  1. This PR — device-flow linking (phase 0)
  2. FrameOS Cloud 2/4: cloud login on backends and frames #264 — cloud login (phase 1)
  3. FrameOS Cloud 3/4: scene and frame config backups #265 — scene/frame config backups (phase 3)
  4. FrameOS Cloud 4/4: cloud store and "My cloud drive" #257 — cloud store + "My cloud drive" (phase 2)

Links a FrameOS backend or a standalone frame to cloud.frameos.net — or any compatible self-hosted provider — via the OAuth 2.0 Device Authorization Grant, with a scoped permission model. All connections are outbound-only and the link token is encrypted at rest.

  • Backend: /api/cloud/{status,provider,connect,poll,disconnect}; the DB tables shipped earlier (2c4a6f8d9b10), this adds the ORM layer, the link lifecycle, and the account-owner fields learned from grants at connect time (+ migration)
  • Frame: the same endpoints implemented on-device in cloud_api_routes.nim, link state in ./state/cloud_link.json
  • Frontend: a "FrameOS Cloud" settings section shared between the backend settings page and the on-device frame admin
  • Safe feature scopes (backups, store publishing) are requested with the link; security-sensitive scopes (cloud login, remote access, …) come later behind an explicit opt-in toggle
  • docs/cloud-link.md documents the complete protocol (including the login/backup/store endpoints that land in the follow-up PRs) so any compatible server can implement it; CLOUD-TODO.md is the phase plan

Test plan

  • pytest app/api/tests/test_cloud.py — 10 passed (full backend suite: 735 passed)
  • nim c -r src/frameos/server/tests/test_auth.nim — green; full frameos compile check passes
  • pnpm --dir frontend run build and the frame admin frontend build pass

🤖 Generated with Claude Code

Phase 0 of CLOUD-TODO.md. Links this install to cloud.frameos.net (or any
compatible self-hosted provider) via the OAuth 2.0 Device Authorization
Grant, with a scoped permission model. The token is encrypted at rest and
every connection is outbound-only; the protocol is documented in
docs/cloud-link.md.

- Backend: /api/cloud/{status,provider,connect,poll,disconnect}, link state
  in cloud_backend_link (tables shipped earlier), account owner learned from
  grants at connect time
- Frame: the same endpoints implemented on-device (cloud_api_routes.nim),
  link state in ./state/cloud_link.json
- Frontend: "FrameOS Cloud" settings section shared between the backend
  settings page and the on-device frame admin
- Safe feature scopes (backups, store publishing) are requested with the
  link; security-sensitive scopes (cloud login, ...) come later with an
  explicit opt-in toggle

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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