POST
/
v1
/
nutrients
/
analyze
curl --request POST \
  --url https://api.mrcook.app/v1/nutrients/analyze \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "ingredients": [
    "500 grams ground beef",
    "4 slices bacon",
    "4 slices cheddar cheese",
    "4 hamburger buns"
  ],
  "servings": "4 servings"
}'
{
  "success": true,
  "data": {
    "calories": 550,
    "carbohydrates": 30.5,
    "protein": 45.2,
    "fat": 28.8,
    "sugar": 5.1,
    "confidence": 92
  }
}

Authorizations

x-api-key
string
header
required

Body

application/json

Response

200
application/json
Successfully analyzed nutrients.

The response is of type object.