04-02-2023 20:23
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

04-02-2023 20:23
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I am very new to Fitbit Development and js in general. Currently, I am able to get the accelerometer data from the app to companion. Now I am searching for a way to access that data on my local computer. According to what different posts the data can be transferred through fetch post method. But, I am not sure how to access the data on the server after sending it from companion.
Current;y I am using
fetch('https://10.0.0.41:441/', {
method:'post',
headers: {
'Content-Type': 'application/json'
},
body:JSON.stringify(evt.data)
}).then(function(result) {
.....
to send data but I am not sure what the server code must look like to display this data on localhost.

04-02-2023 20:40
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


04-02-2023 20:40
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
What you're trying to do is difficult but possible.
For a start, you'll need a non-self-signed security certificate installed on your computer. (I never succeeded in doing this on Windows.)
Then, you'll need to write (or find) a server to run on your computer than can receive the POST requests and save the request data as a file.
Gondwana Software

