Nutrition

Look up a food product by barcode

get/foods/barcode/{upc}

Request

  • Base URL: https://exercise-api.ymove.app/api/v2
  • URL: https://exercise-api.ymove.app/api/v2/foods/barcode/{upc}
  • Auth: one of:
    • API key in header X-API-Key
    • API key in query parameter api_key

Path parameters

upcstring required

UPC or EAN barcode number

Query parameters

countrystring

ISO 3166-1 alpha-2 country code (e.g. "FR", "NL"). When provided, the Open Food Facts fallback is queried with the country locale so nutrition labels and serving descriptions come back localized where available. Also accepted as cc.

Response

Food product with nutrition data

Example response

{
  "data": {
    "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "fdcId": 171077,
    "name": "Chicken, broilers or fryers, breast, skinless, boneless, meat only, cooked, grilled",
    "shortName": "Chicken Breast",
    "displayName": "Chicken Breast (grilled, lean)",
    "brand": null,
    "category": "Poultry Products",
    "servingSize": 100,
    "servingDescription": "100g",
    "calories": 165,
    "protein": 31,
    "fat": 3.6,
    "carbs": 0,
    "fiber": 0,
    "sugar": 0,
    "sodium": 74,
    "cholesterol": 85,
    "saturatedFat": 1,
    "barcode": null,
    "source": "usda"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.