Polar API

102 views
Skip to first unread message

Endre Grüner Ofstad

unread,
May 9, 2019, 1:37:14 PM5/9/19
to golden-cheetah-users
Any efforts being made on connecting Golden Cheetah and Polar API?

Ale Martinez - No direct email please

unread,
May 9, 2019, 5:17:34 PM5/9/19
to golden-cheetah-users
El jueves, 9 de mayo de 2019, 14:37:14 (UTC-3), Endre Grüner Ofstad escribió:
> Any efforts being made on connecting Golden Cheetah and Polar API?
> https://www.polar.com/en/accesslink

There was an API “mismatch” (see https://github.com/GoldenCheetah/GoldenCheetah/issues/2396), I don’t know if it is still the case.
The (beta) ability to download a FIT file looks interesting

Mark Liversedge

unread,
May 10, 2019, 3:46:36 AM5/10/19
to golden-cheetah-users
The previous attempt to integrate was halted because Polarflow (like Garmin Connect) only has a sync API that assumes it is syncing with another website.
Their APIs do not support direct integration from a mobile or desktop app.

Mark

Endre Grüner Ofstad

unread,
May 11, 2019, 11:46:20 AM5/11/19
to golden-cheetah-users
Aah, I see ( I think :P). Hopefully that will change in the future :) Because direct sync with Polar API would allow R-R/laps/weight data associated with each activity to follow as well. 

Ale Martinez - No direct email please

unread,
May 12, 2019, 8:49:02 AM5/12/19
to golden-cheetah-users
El sábado, 11 de mayo de 2019, 12:46:20 (UTC-3), Endre Grüner Ofstad escribió:
> Aah, I see ( I think :P). Hopefully that will change in the future :) Because direct sync with Polar API would allow R-R/laps/weight data associated with each activity to follow as well. 

Currently the R-R data can be exported, but as a separate file: https://support.polar.com/en/support/how_can_i_export_my_rr_recording_from_flow_web_service

Holger

unread,
Mar 23, 2020, 3:45:43 AM3/23/20
to golden-cheetah-users
Polar needs a "Authorization callback domain" in their Accesslink Application details
The example is http://localhost:5000/oauth2_callback

Adding your details CLIENT_ID and CLIENT_SECRET to the config.yml (given to you while creating the Accesslink client)
Start the python file and visit http://localhost:5000
this redirects you to the login screen from polar (https://flow.polar.com/oauth2/authorization?client_id=CLIENT_ID&response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A5000%2Foauth2_callback)
login in and granting access to Athlete-Data
and returns TOKEN to the "Authorization callback domain" as append "?code=TOKEN" (http://localhost:5000/oauth2_callback?code=TOKEN)

Which "Authorization callback domain" is needed for GoldenCheetah?

Mark Liversedge

unread,
Mar 23, 2020, 3:58:15 AM3/23/20
to golden-cheetah-users
Holger,

The authentication mechanism is Oauth2 and not really an issue.

The main problem is the API will push data once and once only, it assumes it is communicating with another website and data store.
Notifications are sent to the website that data is ready to pull and then the data is requested via a pull to sync.

It is not possible to query or request data on demand- a feature needed by mobile apps or desktop apps like GoldenCheetah.

Mark
Reply all
Reply to author
Forward
0 new messages