šŸ”µāš« Autocompute a daily goal for a specific list of nutrients.

Automatically computes and posts a daily intake goal given a list of nutrients and a user. There is an optional force parameter that will not take into consideration if the user had previous goals for the nutrients in the list and will recompute and update them. Otherwise the daily nutritional goals a user has will be taken into consideration and won't be updated. If force is not true only the nutrients in the nutrient list that don't have a goal defined for the user will be calculated.

Ā 

If the nutrient list is empty or it isn't passed all computable nutrient goals will be recalculated if force is true. Existing goals without a supported automatic calculation are preserved even with force=true. Otherwise only the ones missing in the user's goals. If force is not passed it will be false by default.

Ā 

Energy and macronutrients use the revised Harris-Benedict equation (1984) by default, or Mifflin-St Jeor (1990) when bmr_formula='mifflin_st_jeor'; estimated resting calories are multiplied by the lifestyle activity factor, then allocated as 45% carbohydrate, 20% protein, and 35% fat. Macro targets and ranges are in grams. For vitamins and minerals, fiber, folate equivalents and alpha-linolenic acid, the age/sex-based reference values follow US National Academies DRIs (RDAs/AIs), summarized in NASEM (2019) Appendix J, https://doi.org/10.17226/25353. Sodium uses the DRI Adequate Intake and age-specific Chronic Disease Risk Reduction threshold, not a tolerable upper limit. Other nutrient limits are separate heuristic rules and are not DRIs. These estimates are for the general population, not individualized athlete or clinical prescriptions. The user profile attributes used for macro calculations are sex, height, weight, birth and lifestyle; other nutrients use age/sex references or calorie-based rules as appropriate. If the user does not have enough information on its profile, global average values are used for each non-provided user profile attribute.

Ā 

The available indicators with their respective units can be found by using the endpoint '/v2/info/nutrients'.

Ā 

The following nutrients do not give an autocalculation. They will appear as null in the response (manual goal can still be set): F20D5, F22D6, FOLAC, FOLFD, CAFFN, ALC. GI and GL are not autocomputed either.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params

Parameters to autocompute the daily nutritional goals

integer
required

ID of the user to add a goal to. You must be the owner have access to the user in order to do any modification.

nutrient_list
array

Nutrients you want compute automatically taking into account the force parameter. If empty or not passed all the available nutrients will be computed

nutrient_list
boolean

If true, recompute supported nutrients, preserving manual goals without an automatic equivalent. If false, only compute nutrients without existing goals. Defaults to false.

string
enum
Defaults to harris_benedict

Optional energy equation for new computations; does not change previously stored goals unless force is true.

Allowed:
Responses
200

Daily nutritional goals successfully calculated!

401

Unauthorized, invalid token.

403

Forbidden

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json