Endpoint
Path Parameters
The unique numeric ID of the foodConstraints: Must be a positive integer (>= 1)Example:
/foods/1234Response
Indicates if the request was successful
Complete food object
Unique numeric food identifier
Food name
Data source:
nutritional_table, user_contributed, or ai_generatedMain category (e.g., “Frutas”, “Legumes”, “Cereais”)
Subcategory (level 2)
Sub-subcategory (level 3)
URL to food image (if available)
FODMAP information (null if not available)
FODMAP level:
free, low, medium, or highPortion-specific notes (e.g., “1/2 cup”, “100g”)
Additional FODMAP notes or warnings
Metadata about how FODMAP data was matched
Type of match:
single_ingredient or multiple_ingredientsFODMAP category (for single ingredient)
English name from FODMAP database
Keyword that triggered the FODMAP match
Number of ingredients (for multiple_ingredients match)
Nutritional information (null if not available)
Energy in kilocalories
Energy in kilojoules
Reference portion (typically “100g”)
Complete macronutrient breakdown
Total fats in grams
Saturated fats in grams
Monounsaturated fats in grams
Polyunsaturated fats in grams
Linoleic acid in grams
Trans fats in grams
Cholesterol in milligrams
Total carbohydrates in grams
Sugars in grams
Oligosaccharides in grams
Starch in grams
Protein in grams
Dietary fiber in grams
Salt in grams
Alcohol in grams
Water content in grams
Organic acids in grams
Ash content in grams
Vitamin content as key-value pairs (e.g.,
{"vitamin_c_mg": "10.5"})Mineral content as key-value pairs (e.g.,
{"calcium_mg": "120"})Information about data sources
Source of nutritional data (e.g., “Portuguese Nutrition Table”)
Source of FODMAP data (e.g., “Monash University FODMAP Database”)
Number of times this food has been searched (incremented by this request)
ISO 8601 timestamp when the food was created
ISO 8601 timestamp when the food was last updated
Examples
Get food by ID
Response Example
Error Responses
404 Not Found
Returned when a food with the specified ID does not exist.400 Bad Request
Returned when the ID parameter is invalid (not a positive integer).Notes
- This endpoint increments the
searchCountfield each time it’s called (analytics) - The search count increment happens asynchronously and won’t affect response time
- Foods may have FODMAP data, nutrition data, both, or neither
- The
fodmap.search_informationfield provides transparency about how FODMAP data was matched