post https://api.logmeal.com/v2/nutritional_plan
Creates and assigns a new nutritional plan to the specified user.
If a nutritional plan already exists for today's date, it will be deleted and replaced. If there's an active plan, it will be deactivated.
Requirements
- The user profile must contain the following data:
- Weight
- Height
- Sex
- Lifestyle
- If missing, the request will fail with a detailed error and instructions to update the profile using:
-
/v2/profile/modifyUserProfileInfo
(š“ APIUSER) -
/v2/users/modifyUserProfileInfo
(šµ APIUSERMANAGER)
-
Field Requirements by Plan Type
- Type: BALANCED_DIET
- Required Fields: type, user_id
Description: No further parameters are required.
- Required Fields: type, user_id
- Type: GAIN_MUSCLE
- Required Fields: type, user_id, growth_intensity, date
Description: Requires both the muscle growth intensity and the goal date to be specified.
- Required Fields: type, user_id, growth_intensity, date
- Type: WEIGHT_LOSS
- Required Fields: type, user_id, weight_goal, date
Description: Requires a target weight and future date.
- Required Fields: type, user_id, weight_goal, date
Refer to the v2/nutritional_plan/info
endpoint to retrieve required fields dynamically based on plan type.