Search foods
Finds a food to use in a plan or recipe: the account’s own foods and the food databases it uses (Settings > Food databases), best 5 matches only, with no further pages. Each account can search 50 times a day (429 past that). The foods a search returns can be read and used by the account for 30 days. Values are per 100 g.
Requires the library:read permission.
/foodsAuthorizationToken Bearer (API Key) · headerobligatorioAlmendra API key, bound to one professional account. Send it as Authorization: Bearer YOUR_API_KEY.
library:readsearchstringobligatorioFood name, at least 3 letters (accents are ignored)
Best matches
foodsFood[]obligatorioMostrar propiedadesOcultar propiedades
Food_idstringobligatorionamestringobligatoriotypestringobligatoriofood: from a food composition database; custom_food: created by an account; recipe: a recipe.
foodcustom_foodrecipesourcestringFood composition database the values come from
categorystringcreatedByThisAccountbooleanobligatoriocaloriesKcalnumberproteinGnumbercarbsGnumberfatGnumbernutrientsobjectobligatorioEvery other nutrient the food has, per 100 g, keyed by name and unit (sodium_mg, vitaminB12_ug, …).
measuresFoodMeasure[]obligatorioHousehold measures and their weight in grams, including the account's own measures for this food. A meal plan's unit is one of these (or grams).
Mostrar propiedadesOcultar propiedades
FoodMeasureamountnumberobligatoriodescriptionstringobligatoriogramsnumberobligatorioInvalid path parameter, query parameter or request body
successbooleanobligatoriofalsemessagestringobligatorioSame as error.message.
errorobjectobligatorioMostrar propiedadesOcultar propiedades
statusintegerobligatorioHTTP status code of the response.
codestringobligatorioMachine-readable error code, stable across versions; branch on this rather than on message.
bad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictpayload_too_largeunsupported_media_typeunprocessable_entityrate_limitedinternal_errornot_implementedbad_gatewayservice_unavailablegateway_timeoutmessagestringobligatorioHuman-readable explanation of what went wrong.
Missing or invalid API key
successbooleanobligatoriofalsemessagestringobligatorioSame as error.message.
errorobjectobligatorioMostrar propiedadesOcultar propiedades
statusintegerobligatorioHTTP status code of the response.
codestringobligatorioMachine-readable error code, stable across versions; branch on this rather than on message.
bad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictpayload_too_largeunsupported_media_typeunprocessable_entityrate_limitedinternal_errornot_implementedbad_gatewayservice_unavailablegateway_timeoutmessagestringobligatorioHuman-readable explanation of what went wrong.
The account behind the API key has no active paid plan, or the key lacks the permission this operation needs
successbooleanobligatoriofalsemessagestringobligatorioSame as error.message.
errorobjectobligatorioMostrar propiedadesOcultar propiedades
statusintegerobligatorioHTTP status code of the response.
codestringobligatorioMachine-readable error code, stable across versions; branch on this rather than on message.
bad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictpayload_too_largeunsupported_media_typeunprocessable_entityrate_limitedinternal_errornot_implementedbad_gatewayservice_unavailablegateway_timeoutmessagestringobligatorioHuman-readable explanation of what went wrong.
Rate limit exceeded (600 requests per 60 seconds); retry after Retry-After seconds
successbooleanobligatoriofalsemessagestringobligatorioSame as error.message.
errorobjectobligatorioMostrar propiedadesOcultar propiedades
statusintegerobligatorioHTTP status code of the response.
codestringobligatorioMachine-readable error code, stable across versions; branch on this rather than on message.
bad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictpayload_too_largeunsupported_media_typeunprocessable_entityrate_limitedinternal_errornot_implementedbad_gatewayservice_unavailablegateway_timeoutmessagestringobligatorioHuman-readable explanation of what went wrong.
Unexpected server error
successbooleanobligatoriofalsemessagestringobligatorioSame as error.message.
errorobjectobligatorioMostrar propiedadesOcultar propiedades
statusintegerobligatorioHTTP status code of the response.
codestringobligatorioMachine-readable error code, stable across versions; branch on this rather than on message.
bad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictpayload_too_largeunsupported_media_typeunprocessable_entityrate_limitedinternal_errornot_implementedbad_gatewayservice_unavailablegateway_timeoutmessagestringobligatorioHuman-readable explanation of what went wrong.