Sign in | Sign up

Getting calories from the v2 API

Tagged:

Currently contains 3 posts

Avatar

July 14, 2020 15:42

rodmclaughlin

I have the free ‘hacker’ subscription. The V2 documentation says you can put search_nutrient=calories as a parameter. When I try to GET this for ‘grilled cheese’ using my api_id and api_key, it returns with
{
“message”: “\”search_nutrient\" is not allowed",
“id”: “9d2a3a31-c66e-407b-af32-1e6a49fd2049”
}

Avatar

July 14, 2020 16:42

rodmclaughlin

Correction – I’ve figured out how to get calories.
https://trackapi.nutritionix.com/v2/search/instant?detailed=true&query=spaghetti bolognese
Thanks

Avatar

July 29, 2020 10:37

bat

hiii how can I calculate calorie ,carb, fat , and protein locally like they did in there android app. how can I calculate it.

Reply to thread