Skip to main content
Solved

Api to calculate the burning calories for given activities


Forum|alt.badge.img+1

I’m using the Strava api’s and having the free subscription, I need to calculate the burned calories of the activity/sport I’m doing,

But I didn’t find any api to fetch all the sports/activities, do anyone suggest any api where I can give the activity name/ sport name like running, swimming, HIIT etc with the time duration and in response it can provide the burned calories in the time period.

Best answer by ActivityFix

Strava includes the calories burned as one of the fields in DetailedActivity (which you can retrieve using getActivityById), the field is simply called 'calories'.

If you are trying to calculate a general number of calories burned in an activity for a specific amount of time (as opposed to an already recorded activity), that isn't likely to be accurate as it is dependent on several other factors. See https://support.strava.com/hc/en-us/articles/216917097-Calorie-Calculation for some details on Strava's calculation.

View original
Did this topic help you find an answer to your question?

2 replies

ActivityFix
Superuser
Forum|alt.badge.img+24
  • Superuser
  • 243 replies
  • Answer
  • March 20, 2023

Strava includes the calories burned as one of the fields in DetailedActivity (which you can retrieve using getActivityById), the field is simply called 'calories'.

If you are trying to calculate a general number of calories burned in an activity for a specific amount of time (as opposed to an already recorded activity), that isn't likely to be accurate as it is dependent on several other factors. See https://support.strava.com/hc/en-us/articles/216917097-Calorie-Calculation for some details on Strava's calculation.


Forum|alt.badge.img+1
  • Author
  • Hub Rookie
  • 1 reply
  • March 28, 2023

Hi @ActivityFix ,Thanks for the details but where I can find all the activities id, I just want to use general activities data, not those which are created  by user


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept, you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings