fix(google-health): surface the connection status and add the resume and test routes

Wire the settings card to the live connection so it reflects reality
after a connect.

- Emit a google-health entry on the consolidated integration-status
  envelope (configured, connected, last sync, backfill, and the
  needs-reconnect flag). Without it the card read an undefined status and
  showed a permanently disconnected connection even after a successful
  OAuth grant, hiding the sync, disconnect, and reconnect controls.
- Add the resume and test-connection routes the card calls, mirroring the
  classic Fitbit ones.
- Use the shared refresh icon on the reconnect action.
- Drop the experimental-scope opt-in from the runbook and describe ECG
  and irregular-rhythm as a planned addition rather than a current toggle.
This commit is contained in:
Marc-André Bombeck committed 2026-07-03 14:41:53 +02:00
1 parent 422a6a7df0
commit 0d3067837e
6 files changed
+241 -14

No files matched your search

+7 -4
View File
@@ -82,10 +82,13 @@ https://www.googleapis.com/auth/googlehealth.sleep.readonly
https://www.googleapis.com/auth/googlehealth.profile.readonly
```
No write scopes are requested — the connection is read-only. The optional ECG
and irregular-rhythm (Pixel Watch clinical) scopes stay off unless an operator
opts in via `GOOGLE_HEALTH_EXPERIMENTAL_SCOPES=true`; they widen the Restricted
review surface and only apply to Pixel Watch sources.
No write scopes are requested — the connection is read-only. These four core
scopes are the full set the client requests today.
ECG and irregular-rhythm notifications (the Pixel Watch clinical data types) are
a **planned** future addition, not a current option — there is no reader for them
yet, so no scope is requested for either. When that support lands the runbook
will document how to opt in; until then leave them out of your OAuth client.
## 5. Wire the credentials in Settings → Integrations