Open schnee opened 1 year ago
It looks like withings is returning a non-standard json, where the contents that httr2 expects are nested within the body
field. Resolving this will require some thought since we'll need to provide some hook to oauth_flow_auth_code()
to allow custom parsing.
(late reply...)
thanks
Related to this comment: https://github.com/mgirlich/httr2/blob/req_body_json-type/R/oauth-flow.R#L5-L8. Looks like we'd need to export oauth_flow_abort()
to provide a complete solution.
When I do this, should also pass correct caller_env()
through so that we can get more informative errors.
I'm attempting to perform the OAUTH flow against the Withings endpoint via the below statements and wind up getting the above error. Looking into oauth_flow_fetch, it appears that this should have been successful, but it is not. Ideas?
The API is documented at https://developer.withings.com/api-reference/#tag/oauth2/operation/oauth2-getaccesstoken