Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

GET Body Fat Logs

ANSWERED

Hello Fitbit Community!

 

I'm having an Issue making a specific request for Body Fat logs, and I can't figure out if it's a documentation issue, or a PEBKAC issue.

 

On the following documentation page: https://dev.fitbit.com/build/reference/web-api/body/#body-fat

The second GET request shows that you can run a GET on 1/user/-/body/log/fat/date/today/1m.json

 

This is returning an invalid Resource error.

{"errors":[{"errorType":"validation","fieldName":"resource path","message":"Invalid time series resource path: /body/log/fat"}]}

Can someone point me to what I'm missing?

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

Hi @tormentz,

 

Welcome to the forums!

 

I'm also able to reproduce the error that you're seeing using the parameters you used. I think the issue is being caused by the "today" value you entered for [date].  When I switch "today" with the actual date in the YYYY-MM-DD, as advised by the documentation, I receive the correct response.

 

Can you let me know if this works for you as well? On the other hand, I will have to follow up with the team to verify if this is the correct error message that should be displayed since I've confirmed that the resource path is valid.

 

I hope this helps. Let me know if you have any additional questions.

 

Hope to hear from you soon.

View best answer in original post

Best Answer
0 Votes
3 REPLIES 3

Hi @tormentz,

 

Welcome to the forums!

 

I'm also able to reproduce the error that you're seeing using the parameters you used. I think the issue is being caused by the "today" value you entered for [date].  When I switch "today" with the actual date in the YYYY-MM-DD, as advised by the documentation, I receive the correct response.

 

Can you let me know if this works for you as well? On the other hand, I will have to follow up with the team to verify if this is the correct error message that should be displayed since I've confirmed that the resource path is valid.

 

I hope this helps. Let me know if you have any additional questions.

 

Hope to hear from you soon.

Best Answer
0 Votes

That did assist, thank you.

 

I find it strange how on some of the date fields (Activities/steps) that you can use "today" and others you cannot.

 

FYI, I assume the other /body/X/logs also have this happen, as I had it happen on weight yesterday as well.

Best Answer
0 Votes

@tormentz I agree, I'll need to get further clarification on the usage of using today vs YYYY-MM-DD as well.

Best Answer
0 Votes