External integration - Withings

Hello everyone :waving_hand:

I’m introducing a new Withings external integration for Gladys. It retrieves data from your Withings scales, blood pressure monitors, watches, and Sleep Analyzers, making it usable in dashboards and scenes.

What it does

A « Withings health » device that groups your data:

  • weight and body composition (fat mass, muscles, bones, water, visceral fat);
  • blood pressure and pulse;
  • blood oxygen (SpO2), body temperature;
  • steps, distance, elevation, and calories for the day;
  • sleep from the last night (duration, deep/light/REM sleep, score, awakenings);
  • « in bed » status with a Sleep Analyzer.

The features adapt to what you actually measure: with just a blood pressure monitor, you won’t have twenty empty boxes for body composition.

Each measurement is recorded at its actual date: a weight synchronized an hour later is placed at the correct time in the history.

A device per Withings battery-powered device, with a « Low Battery » alert.

Scenes (Gladys 5.1+)

Triggers:

  • New Withings measurement (filterable: weight, blood pressure, temperature, oxygen
);
  • « In bed » / « Up » (Sleep Analyzer);
  • Night summary available;
  • Step goal reached (once a day, adjustable goal).

Actions:

  • Refresh Withings data;
  • Read the last Withings value (weight, blood pressure, sleep
), to use it in the rest of the scene.

Example: when a weight measurement arrives, send me « Weight: {{triggerEvent.data.weight}} kg ».

Dashboard widgets

  • Withings Health: live weight, steps, sleep, blood pressure, last measurement, battery status, and a « Refresh » button;
  • Weight Evolution: the curve over one week, one month, three months, or one year.

Real-time with Gladys Plus

  • Without Gladys Plus: Withings is read every 30 minutes (adjustable from 5 min to 24 h).
  • With Gladys Plus: Withings notifies Gladys as soon as data arrives, measurements are there in a few seconds. The « In bed » / « Up » events from the Sleep Analyzer only work with Gladys Plus.

What you need

  • Gladys 5.1 or newer;
  • a Withings account, with your devices synchronized in the Withings app;
  • a Withings developer application (free, takes 5 minutes to create on developer.withings.com). It provides the Client ID and Client secret to paste into Gladys.

Quick installation

  1. Create your application on developer.withings.com (type Public API integration).
  2. Paste the Client ID and Client secret into the integration configuration, then save.
  3. Click on Connect. The first time, Withings refuses the return address: this is normal. Click on Test the connection, copy the displayed URL, and add it to your Withings application.
  4. Click on Connect again. The devices appear in the Discovery tab.

The step-by-step documentation (FR, EN, DE, ES) is here: gladys-withings/docs/fr.md at main · prohand/gladys-withings · GitHub

Privacy

  • The data goes from the Withings cloud directly to your Gladys, via your developer application.
  • Gladys Plus only relays the « new data » notifications, without any measurements in them.
  • The Client secret and tokens are never displayed or written in the logs.

Links

This is a first version: your feedback is welcome, especially if you have devices I couldn’t test (Body Scan, ScanWatch, Thermo, BPM Core
). Don’t hesitate to share your scenes! :slightly_smiling_face:

PR in progress to add features: Add a health device feature category by prohand · Pull Request #3205 · GladysAssistant/Gladys · GitHub

@pierre-gilles Any news on this PR please? :slight_smile:

Hi @prohand,

Thanks a lot for the PR, it’s great and it will open up a lot of possibilities!

As I explained in this post: Gladys d'ici fin 2026 : une grande nouvelle et un plan ambitieux 🚀 - #68 by pierre-gilles

I’m about to go on paternity leave, and until then I avoid merging “sensitive” changes, that is, anything that touches the data model or the API. These are changes that are difficult to roll back once in production: a database migration or a new endpoint, once users and integrations rely on them, we have to maintain them in the long term. If there is an issue after deployment, I need to be available to fix it quickly, and as my partner can give birth at any moment, I can’t guarantee that.

I therefore devote my last weeks (which can stop from one day to the next!) to bug fixes and UI/UX improvements, changes that are much less risky. It’s not a bad thing, there were quite a few things to improve on that side :wink:

Your PR is therefore not at all set aside, it’s just a matter of timing: I keep it on hand and I’ll come back to it when I return. Thanks again for your contribution :folded_hands:

Hi @pierre-gilles

No worries, I completely understand and thank you for the feedback :slight_smile:

On that note, if you’re looking to make some « cosmetic » changes, there are a few in the « feature requests » category :see_no_evil_monkey: