⚫🔴🔵 List all user intakes with their nutritional information and ingredients between two dates. ⏱

(S) Limited amount of calls per second.

 

This endpoint provides a history of the user's intakes between two dates based on the content of the images the user has uploaded during that period of time.

 

The response contains a list with information about every single intake uploaded by the user (containing the timestamp, occasion, nutritional information, ingredients list and the URL to the image*), as well as the total intake of the main nutrients obtained from the images (calories, carbohydrates, fat and protein). All elements in the intakes list are sorted from older to newer.

 

If a food segmentation has been applied on one of the images (see /segmentation endpoints), then three extra attributes will be returned in the response. The attribute 'nutritional_info_per_item', which contains the detailed nutritional information for each of the food segments/regions that have been detected or confirmed on the image; 'recipe_per_item', which contains the list of ingredients for each segment/region detected; and 'segmentation_data', which contains the list of food segments/regions that have been detected automatically on the image. Note that the segmentation_data might not be directly applicable to the uploaded image size. The segmentation pixel values are scaled depending on the 'processed_image_size' values provided for each of the images (the images might be sometimes resized depending on the needs of the food recognition algorithms used).

 

Be aware that not all the entries of this response will contain nutritional information and ingredients list. If the images have not been confirmed or don't have any prediction on a dish level, the nutritional information won't be generated. If the element from the intake list has the flag 'hasNutritionalInfo' set to False, 'nutritional_info' won't be present in the object. Also, confirmed dishes that are not in the 'logmeal' database won't contribute to the nutritional information. They will still be returned in the 'foodNames' field, and will be represented with a null value in the 'ids' field.

 

If Food Waste Detection services are included in your LogMeal Subscription, an extra field named 'food_waste' will be included for each of the intakes or images returned by this endpoint. If there is currently no waste image assigned to a specific intake, then the field 'food_waste' will take the value None/null. Otherwise, the full information included for each intake will be also provided for the corresponding food waste image. The 'food_waste' contains an additional attribute named 'matches_mapping_pre_to_waste', which provides a mapping between the preconsumption image 'food_item_position's to the waste image original 'food_item_position's predictions provided inside 'segmentation_data'. This allows to reference the predicted items positions in the image. If some element is mapped to null means that the food item is not present in the waste image, thus it was completely consumed. Furthermore, also if Food Waste Detection services are included in your LogMeal Subscription, an extra field named 'actual_intake0 will be included for each of the intakes. This information will be complementary to the 'food_waste' previously described and it will specify the actual food intake by subtracting the initially reported image minus the food waste detected.  

Note: for security purposes, the URLs provided to load the images have an expiration time of 1h since their creation. If they get expired you will have to request a new url.

Language
Credentials
Bearer
JWT
Click Try It! to start a request and see the response here!