12-28-2018 08:50
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

12-28-2018 08:50
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hello,
I am trying to authorize my Fitbit settings app using the OAuth feature for Dexcom since they just opened up their API.
Here is what I am trying to do:
<Oauth title="Login" label="Dexcom" authorizeUrl="https://sandbox-api.dexcom.com/v2/oauth2/login" requestTokenUrl="https://sandbox-api.dexcom.com/v2/oauth2/token" clientId="tV2Qrqtj2........TJqjDZk9eReLbc8" clientSecret="0aU7Y.....K0kr9E" scope="offline_access" response_type="code" grant_type="authorization_code"
redirect_uri="https://app-settings.fitbitdevelopercontent.com/simple-redirect.html" onReturn = { async (data) => { console.log("HERE") }} />
But when I attempt it: I get "An Internal Server error occurred, could not process the request".
I don't understand what I am doing wrong, could you give me a little bit of help?
12-28-2018 11:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post



12-28-2018 11:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
This appears to be an issue on the OAuth providers side. You'd have to ask the OAuth provider why they're returning 500 error codes during the OAuth flow.

12-28-2018 11:25
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

12-28-2018 11:25
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Thank you for your reply.
If instead of using
<Oauth>
I have had success with using
<Link source="https://sandbox-api.dexcom.com/v2/oauth2/login?client_id=tV2Qrqtj2PhXluCfVTJqjDZk9eReLbc8&redirect_uri=https://app-settings.fitbitdevelopercontent.com/simple-redirect.html&response_type=code&scope=offline_access&state=25" >Link</Link>
But when it redirects, I get "Invalid Callback URL". Do you know how to redirect it back to the companion settings with the data payload?

01-08-2019 12:07
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

01-08-2019 12:07
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I dont have an answer on the OATH problem, but just making sure you know that all dexcom API glucose data is at least 3 hours behind. So you cant use it for immediate glucose readings. see Data Availability at: https://developer.dexcom.com/endpoint-overview

