āš«šŸ”µ Modify a user's profile information.

This endpoint allows you to modify the profile and main attributes of an end-user (APIUser). This information associated to the user can be used for features like improving and customizing the output of the food recognition capabilities, personalizing the nutrition recommendations and nutrition plans, adapting to the user intake patterns, etc.

Ā 

Read the specification of the request body to see the available fields with their descriptions.

Ā 

This endpoint is the same as /v2/profile/modifyUserProfileInfo and /v2/users/modifyUserProfileInfo.

Ā 

šŸŒ Geographic and Language Personalization

We highly recommend including the optional fields country and language in the request body:

  • country (ISO 3166‑1 alpha‑2 code, e.g., US, FR, JP):
    Providing the country allows LogMeal to geographically refine its food recognition capabilities.
    This enables improved detection accuracy for region-specific dishes and eating patterns, leading to better personalization in nutrition analysis.

  • language (e.g., en, es, fr):
    Setting the preferred language ensures that the names of food items, ingredients, nutrients, and other elements are returned in the specified language, offering a better user experience tailored to each APIUser.

Including these parameters increases the contextual accuracy and relevance of all subsequent API responses.

Ā 

šŸ„— Customizing Recommended Food Group Consumption

You can also use this endpoint to customize the recommended daily or weekly food group portions for a user by passing the min_max_food_groups field.
This allows setting personalized minimum and/or maximum portion limits per food group, which will be taken into account during dietary analysis and goal calculations.

Ā 

Important constraints:

  • If you want to indicate that a food group has no minimum requirement, use null as the min value. You must not use 0, since 0 would imply the user is expected to consume exactly 0 portions, which is incorrect for min.

  • If you want to explicitly restrict a user from consuming a food group, set the max value to 0. This means that any intake of that group will be considered a deviation from the goal.

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

ID of the APIUser.

Body Params

Parameters to be modified, all fields are optional except 'user_id'. Null values will be ignored.

string

Name of the user (min length=2, max length=30)

string

Surname of the user (min length=2, max length=50)

string
enum

APIUser's default language. It must be a three-letter ISO 639-2/T code.

integer
enum

Sex of the user. It must be a number, following ISO/IEC 5218.

Allowed:
number

Weight of the user in Kilograms.

number

Height of the user in Centimeters.

string

Date of birth of the user, following the format "YYYY-MM-DD"

string
enum

Lifestyle of the user. Possible values are ["sedentary", "light", "moderate", "high", "very high"].

Allowed:
string

Will be used for refining the food recognition capabilities. A 2-letter country code according to ISO 3166-1.

string
enum

Default portion size for the user. Possible values are ["small", "medium", "large"]

Allowed:
string
enum

Default salt level for the user. Possible values are ["none", "low", "medium", "high"]

Allowed:
string
enum
Allowed:
string
enum

Default oil level for the user. Possible values are ["none", "low", "medium", "high"]

Allowed:
integer

ID of the sugar ingredient the user usually uses. A list of all possible oil modifiers can be retrieved by calling /dataset/referenceIngredients.

integer

ID of the oil ingredient the user usually uses. A list of all possible oil modifiers can be retrieved by calling /dataset/referenceIngredients.

reference_nutrients
array of strings

Nutrients set as reference (important) for the user

reference_nutrients
string

Timezone the user is located at. This requires a TZ database name; you can find them here https://en.wikipedia.org/wiki/List_of_tz_database_time_zones

integer
required

ID of the user to be modified. You must be the owner of the user to do any modification.

diet_labels
array of strings

This attribute is optional. These are the diet labels of the user. Possible values are ["Balanced", "High-Fiber", "High-Protein", "Low-Carb", "Low-Fat", "High-Sodium", "Low-Sodium"]. The information is used for personalizing the recipe recommendation for the user.

diet_labels
food_restrictions
array of strings

This attribute is optional. These are food restrictions and allergies of the user. The information is used for personalizing the recipe recommendation for the user

food_restrictions
string
enum

Set the user's preferred system for measuring weights.

Allowed:
string
enum

Set the user's preferred way to see food quantity information.

Allowed:
min_max_food_groups
object

Customize the recommended minimum and/or maximum portions per food group.

This field allows setting user-specific dietary goals by specifying optional min and/or max values for one or more food groups.

Ā 

Important notes:

  • If you want to indicate no minimum for a food group, use null as the min value. Do not use 0, as that implies a strict minimum intake of 0 portions.

  • If you want to prevent the user from consuming a food group, set max to 0.

Ā 

Example:

"min_max_food_groups": {

    "fish": {"min": null, "max": 1},

    "red meat": {"min": null, "max": 0},

    "fruit": {"min": 3, "max": 5},

}

Ā 

Available Food Groups:

  • ['Dairy Products', 'Vegetables', 'Grains and Tubers', 'Water', 'Fruit', 'Whole Grain', 'Meat', 'Fish', 'Nuts', 'Legumes', 'Egg', 'Red Meat']
Responses

401

Unauthorized, invalid token

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