Withings WS-50 Scale Syncer - Temperature & CO2
Moderator: leecollings
-
- Posts: 1601
- Joined: Friday 18 October 2013 23:33
- Target OS: Raspberry Pi / ODroid
- Domoticz version: BETA
- Location: Arnhem/Nijmegen Nederland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
kick....
dear all..
Does some have the weigt options implement in Domoticz...
The temp and co is nice, only the scale is what i mis..
There is a api..
http://oauth.withings.com/api/doc
Only i do not understand a &^%&^of all that data....
Looks that this nice hardware have more potention in domoticz..
My wife weight rising....
Eveyday a mail to ... you are to,,,,,
when she lost some weight, send a mail, good job love..
Some one?
dear all..
Does some have the weigt options implement in Domoticz...
The temp and co is nice, only the scale is what i mis..
There is a api..
http://oauth.withings.com/api/doc
Only i do not understand a &^%&^of all that data....
Looks that this nice hardware have more potention in domoticz..
My wife weight rising....
Eveyday a mail to ... you are to,,,,,
when she lost some weight, send a mail, good job love..
Some one?
Xu4: Beta Extreme antenna RFXcomE,WU Fi Ping ip P1 Gen5 PVOutput Harmony HUE SolarmanPv OTG Winddelen Alive ESP Buienradar MySensors WOL Winddelen counting RPi: Beta SMAspot RFlinkTest Domoticz ...Different backups
-
- Posts: 722
- Joined: Friday 02 October 2015 12:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Finland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Any idea what changed in the api around 31.1.2017? Now getting just:
I'll try to check it but if someone knows already...
Code: Select all
Withings WS-50 Syncer Version 0.4.6
[-] Attaching database /home/pi/domoticz/domoticz.db [version 110]
[-] Authenticating at account.withings.com
HTTP ERROR 500
-
- Posts: 115
- Joined: Monday 12 October 2015 15:26
- Target OS: Linux
- Domoticz version: 2.3295
- Location: NL
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Nautilus wrote:Any idea what changed in the api around 31.1.2017? Now getting just:I'll try to check it but if someone knows already...Code: Select all
Withings WS-50 Syncer Version 0.4.6 [-] Attaching database /home/pi/domoticz/domoticz.db [version 110] [-] Authenticating at account.withings.com HTTP ERROR 500
They implemented protection against cross-site request forgery (CSRF) hence a csrf_token needed to be added to the authentication request. Should be fixed through latest commit dd74fce. Please confirm this is also working on your end.
-
- Posts: 722
- Joined: Friday 02 October 2015 12:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Finland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Indeed it works, thanks a lot!
edit: for reference to others, I first ran:
edit: for reference to others, I first ran:
Code: Select all
sudo apt-get install libxml2-dev libxslt-dev python-dev
sudo pip install lxml
Last edited by Nautilus on Friday 10 February 2017 12:31, edited 1 time in total.
-
- Posts: 115
- Joined: Monday 12 October 2015 15:26
- Target OS: Linux
- Domoticz version: 2.3295
- Location: NL
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
I added a requirements.txt file to repository to clarify the required depandanciesNautilus wrote:Indeed it works, thanks a lot!
edit: for reference to others, I first runCode: Select all
sudo apt-get install libxml2-dev libxslt-dev python-dev sudo pip install lxml
-
- Posts: 1601
- Joined: Friday 18 October 2013 23:33
- Target OS: Raspberry Pi / ODroid
- Domoticz version: BETA
- Location: Arnhem/Nijmegen Nederland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Dear all.
Is there somebody that have the weight working in Domoticz....
Is there somebody that have the weight working in Domoticz....
Xu4: Beta Extreme antenna RFXcomE,WU Fi Ping ip P1 Gen5 PVOutput Harmony HUE SolarmanPv OTG Winddelen Alive ESP Buienradar MySensors WOL Winddelen counting RPi: Beta SMAspot RFlinkTest Domoticz ...Different backups
-
- Posts: 722
- Joined: Friday 02 October 2015 12:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Finland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
I think there was someone here who had a working IFTTT example on how to update the weights. See viewtopic.php?f=38&t=9482&p=74115&hilit ... ttt#p66051Derik wrote:Dear all.
Is there somebody that have the weight working in Domoticz....
-
- Posts: 115
- Joined: Monday 12 October 2015 15:26
- Target OS: Linux
- Domoticz version: 2.3295
- Location: NL
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Code has been updated and is now working again after Withings became part of the Nokia company.
-
- Posts: 1601
- Joined: Friday 18 October 2013 23:33
- Target OS: Raspberry Pi / ODroid
- Domoticz version: BETA
- Location: Arnhem/Nijmegen Nederland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Thanks...
Only is there perhaps a option to read the weight of the scale??
Only is there perhaps a option to read the weight of the scale??
Xu4: Beta Extreme antenna RFXcomE,WU Fi Ping ip P1 Gen5 PVOutput Harmony HUE SolarmanPv OTG Winddelen Alive ESP Buienradar MySensors WOL Winddelen counting RPi: Beta SMAspot RFlinkTest Domoticz ...Different backups
-
- Posts: 722
- Joined: Friday 02 October 2015 12:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Finland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Works great, thanks!dynasticorpheus wrote:Code has been updated and is now working again after Withings became part of the Nokia company.
- felix63
- Posts: 244
- Joined: Monday 07 December 2015 9:30
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2020.1
- Location: Gouda
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Hi,
I thought to give it another try. Still not getting any data. Request has been (re)installed. Would you have any other suggestions?
I thought to give it another try. Still not getting any data. Request has been (re)installed. Would you have any other suggestions?
- Spoiler: show
Code: Select all
pi@viola:~/domoticz/scripts/python $ ./ws50-sync.py -u [email protected] -p yyyyyyy -d /home/pi/domoticz/domoticz.db -t 441 -c 440 -l 7 -f -r
Withings WS-50 Syncer Version 0.4.9
[-] Attaching database /home/pi/domoticz/domoticz.db [version 118]
[-] Authenticating at scalews.withings.net
[-] Removing existing data from table METER
[-] Downloading all measurements recorded after 2018-04-14 17:43:47 (7 day limit)
[-] Updating CO2 HOURLY table with 0 measurements [TRUE]
[-] Removing existing data from table MULTIMETER_CALENDAR
[-] Updating CO2 YEARLY table with 0 measurements [TRUE]
[-] Calculating daily MIN, MAX & AVG values
[-] Removing existing data from table TEMPERATURE
[-] Downloading all measurements recorded after 2018-04-14 17:43:47 (7 day limit)
[-] Updating TEMPERATURE HOURLY table with 0 measurements [TRUE]
[-] Removing existing data from table TEMPERATURE_CALENDAR
[-] Updating TEMPERATURE YEARLY table with 0 measurements [TRUE]
[-] Calculating daily MIN, MAX & AVG values
[-] Nothing to commit, closing database
pi@viola:~/domoticz/scripts/python $
-
- Posts: 722
- Joined: Friday 02 October 2015 12:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Finland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
I guess they've done another change. I'm getting some authentication related errors:dynasticorpheus wrote: ↑Monday 03 July 2017 15:50 Code has been updated and is now working again after Withings became part of the Nokia company.
Code: Select all
Withings WS-50 Syncer Version 0.4.8
[-] Dry run mode enabled, no changes to the database will be made
[-] Attaching database /home/pi/domoticz/domoticz.db [version 129]
From cffi callback <function _verify_callback at 0x75f09130>:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 309, in wrapper
_lib.X509_up_ref(x509)
AttributeError: 'module' object has no attribute 'X509_up_ref'
Traceback (most recent call last):
File "/home/pi/domoticz/scripts/ws50-sync.py", line 258, in <module>
main()
File "/home/pi/domoticz/scripts/ws50-sync.py", line 221, in main
deviceid, sessionkey = authenticate_withings(args.username, args.password)
File "/home/pi/domoticz/scripts/ws50-sync.py", line 125, in authenticate_withings
requests.head(URL_USAGE, timeout=3, headers=HEADER, allow_redirects=True, verify=pem)
File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 98, in head
return request('head', url, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 58, in request
return session.request(method=method, url=url, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 506, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='goo.gl', port=443): Max retries exceeded with url: /z6NNlH (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')],)",),))
-
- Posts: 148
- Joined: Tuesday 01 October 2013 8:31
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2023.2
- Location: Sweden
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Guess that we can expect this to change again as Nokia sold of the Withings section back to the founder again and that end of this year Withings will be fully separated once again.dynasticorpheus wrote: ↑Monday 03 July 2017 15:50Code has been updated and is now working again after Withings became part of the Nokia company.
-
- Posts: 148
- Joined: Tuesday 01 October 2013 8:31
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2023.2
- Location: Sweden
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
Following notification is provided at the above API documentation page:
This documentation is deprecated.
The Health Mate API is now fully functional with OAuth 2.0 authentication protocol.
Therefore, the OAuth 1.0 process will no longer be supported beginning:
November 30, 2018
Please refer to the new documentation for migrating to OAuth 2.0.
Please have a look at our other important non-backward-compatible changes in our release note.
-
- Posts: 115
- Joined: Monday 12 October 2015 15:26
- Target OS: Linux
- Domoticz version: 2.3295
- Location: NL
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
A bit late to the party as I a moved over to Home Assistant. Just did a full update and it is still working for me so am I missing something? Please note I am not using their official API as they do not support the temperature / CO2 part. (Basically the main reason for building this script)
Code: Select all
Withings WS-50 Syncer Version 0.4.9
[-] Dry run mode enabled, no changes to the database will be made
[-] Attaching database /home/dynasticorpheus/x-tools/builds/domoticz-x64/domoticz.db [version 129]
[-] Authenticating at scalews.withings.net
[-] Removing existing data from table METER
[-] Downloading all measurements recorded after 2018-09-08 11:53:24 (1 day limit)
[-] Updating CO2 HOURLY table with 0 measurements [FALSE]
[-] Removing existing data from table MULTIMETER_CALENDAR
[-] Updating CO2 YEARLY table with 44707 measurements [FALSE]
[-] Calculating daily MIN, MAX & AVG values
[-] Removing existing data from table TEMPERATURE
[-] Downloading all measurements recorded after 2018-09-08 11:53:24 (1 day limit)
[-] Updating TEMPERATURE HOURLY table with 0 measurements [FALSE]
[-] Removing existing data from table TEMPERATURE_CALENDAR
[-] Updating TEMPERATURE YEARLY table with 44707 measurements [FALSE]
[-] Calculating daily MIN, MAX & AVG values
[-] Nothing to commit, closing database
Nautilus wrote: ↑Tuesday 24 July 2018 23:42I guess they've done another change. I'm getting some authentication related errors:dynasticorpheus wrote: ↑Monday 03 July 2017 15:50 Code has been updated and is now working again after Withings became part of the Nokia company.It seems that at least Oauth1.0 is now deprecated (http://developer.health.nokia.com/oauth2/).Code: Select all
Withings WS-50 Syncer Version 0.4.8 [-] Dry run mode enabled, no changes to the database will be made [-] Attaching database /home/pi/domoticz/domoticz.db [version 129] From cffi callback <function _verify_callback at 0x75f09130>: Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 309, in wrapper _lib.X509_up_ref(x509) AttributeError: 'module' object has no attribute 'X509_up_ref' Traceback (most recent call last): File "/home/pi/domoticz/scripts/ws50-sync.py", line 258, in <module> main() File "/home/pi/domoticz/scripts/ws50-sync.py", line 221, in main deviceid, sessionkey = authenticate_withings(args.username, args.password) File "/home/pi/domoticz/scripts/ws50-sync.py", line 125, in authenticate_withings requests.head(URL_USAGE, timeout=3, headers=HEADER, allow_redirects=True, verify=pem) File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 98, in head return request('head', url, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 506, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='goo.gl', port=443): Max retries exceeded with url: /z6NNlH (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')],)",),))
-
- Posts: 722
- Joined: Friday 02 October 2015 12:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Finland
- Contact:
Re: Withings WS-50 Scale Syncer - Temperature & CO2
dynasticorpheus wrote: ↑Sunday 09 September 2018 11:57 A bit late to the party as I a moved over to Home Assistant. Just did a full update and it is still working for me so am I missing something? Please note I am not using their official API as they do not support the temperature / CO2 part. (Basically the main reason for building this script)
Indeed, works fine after switching to Python 3 Sorry for the false alarm...
Who is online
Users browsing this forum: No registered users and 1 guest