Severity
minor
Summary
For the intraday subcommand, JSON keys and CSV headers describe the same fields with different names, and JSON also drops the datetime column entirely. Cross-format consumers have to maintain two name maps.
Reproduce
$ withings-export intraday --since 1d | head -1
timestamp,datetime,duration_sec,steps,distance_m,elevation_m,calories,heart_rate,hrv_rmssd,hrv_sdnn1,hrv_quality,spo2_auto,model,model_id
$ withings-export intraday --since 1d --json | jq '.[0] | keys'
[
"calories", "distance", "duration", "elevation", "heart_rate",
"hrv_quality", "model", "model_id", "rmssd", "sdnn1",
"spo2_auto", "steps", "timestamp"
]
Mismatches:
| CSV |
JSON |
duration_sec |
duration |
distance_m |
distance |
elevation_m |
elevation |
hrv_rmssd |
rmssd |
hrv_sdnn1 |
sdnn1 |
datetime |
(missing) |
Other subcommands (activity, workouts, measurements) keep names roughly aligned, so intraday is the odd one out.
Expected
Either:
- Pick one canonical name per field and use it in both serializers (preferred —
heart_rate / hrv_rmssd / duration_sec-style snake_case with units), or
- Document the mapping in
prime and the README.
Notes
The unit-suffixed CSV names (_sec, _m) are useful in spreadsheets; matching them in JSON is fine. The bigger ask is hrv_rmssd ↔ rmssd and the missing datetime in JSON.
Severity
minor
Summary
For the
intradaysubcommand, JSON keys and CSV headers describe the same fields with different names, and JSON also drops thedatetimecolumn entirely. Cross-format consumers have to maintain two name maps.Reproduce
Mismatches:
duration_secdurationdistance_mdistanceelevation_melevationhrv_rmssdrmssdhrv_sdnn1sdnn1datetimeOther subcommands (
activity,workouts,measurements) keep names roughly aligned, sointradayis the odd one out.Expected
Either:
heart_rate/hrv_rmssd/duration_sec-style snake_case with units), orprimeand the README.Notes
The unit-suffixed CSV names (
_sec,_m) are useful in spreadsheets; matching them in JSON is fine. The bigger ask ishrv_rmssd↔rmssdand the missingdatetimein JSON.