Open Food Facts API: Get packaged food product
Looks up a packaged food by barcode or by product name and brand, returning ingredients, allergens, Nutri-Score, NOVA processing level and nutrition from Open Food Facts.
Unofficial. Not affiliated with or endorsed by Open Food Facts.
Inputs
Values from the run on Oct 23, 2026, shown under Output.
- Product, required
product Product name with brand or barcode printed on the pack, for example Nutella Ferrero or 3017620422003.
Nutella Ferrero
Input as JSON
{ "product": "Nutella Ferrero"}Output
{ "brand": "Nutella, Ferrero", "barcode": "8000500225615", "quantity": "290 g", "allergens": [ "Milk", "Nuts", "Soybeans" ], "photo_link": "https://images.openfoodfacts.org/images/products/800/050/022/5615/front_en.18.400.jpg" , "nova_number": 4, "nutri_score": "E - poor nutritional quality", "product_name": "Nutella Ferrero", "ingredients_text": "SUGAR, EDIBLE VEGETABLE OIL, HAZELNUTS 13%, LOW FAT COCOA POWDER 7.4%, SKIMMED COW MILK POWDER 6.6%, WHEY POWDER, EMULSIFIER (LECITHIN (INS 322)), FLAVOUR (NATURE IDENTICAL FLAVOURING SUBSTANCE (VANILLIN)).", "processing_level": "Ultra-processed food", "countries_sold_in": [ "Bolivia", "India", "Turkey" ], "nutrition_per_100g": { "fat_g": 30.9, "salt_g": 0, "fibre_g": 0, "sugars_g": 56.3, "protein_g": 6.3, "energy_kcal": 533, "carbohydrates_g": 57.5, "saturated_fat_g": 10.6 }, "open_food_facts_link": "https://world.openfoodfacts.org/product/8000500225615" , "nutrition_per_serving": { "fat_g": 4.63, "salt_g": 0, "fibre_g": 0, "sugars_g": 8.44, "protein_g": 0.945, "energy_kcal": 80, "carbohydrates_g": 8.62, "saturated_fat_g": 1.59 }}Code
curl https://api.fous.com/v1/runs \ -H "Authorization: Bearer $FOUS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"method":"openfoodfacts.org/get_product","input":{"product":"Nutella Ferrero"}}' # Save as fous.py, then run: python3 fous.pyimport json, os, timefrom urllib.error import HTTPErrorfrom urllib.request import Request, urlopenAPI = "https://api.fous.com/v1/runs" KEY = os.environ["FOUS_API_KEY"]HEADERS = { "Authorization": f"Bearer {KEY}", "Content-Type": "application/json" ,}def call(url, body=None): data = json.dumps(body).encode() if body else None request = Request(url, data, HEADERS) try: with urlopen(request, timeout=120) as r: return r.status, json.load(r) except HTTPError as error: message = json.load(error)["error"]["message"] raise RuntimeError(message) from errorstatus, run = call(API, { "method": "openfoodfacts.org/get_product" , "input": { "product": "Nutella Ferrero" }})# 202: still going after 30 s. Ask again until it ends.while status == 202: time.sleep(2) status, run = call(f"{API}/{run['id']}")print(json.dumps(run["data"], indent=2))// Save as fous.mjs, then run: node fous.mjsconst api = "https://api.fous.com/v1/runs" ;const headers = { Authorization: `Bearer ${process.env.FOUS_API_KEY}`, "Content-Type": "application/json" ,};let response = await fetch(api, { method: "POST", headers, body: JSON.stringify({ "method": "openfoodfacts.org/get_product" , "input": { "product": "Nutella Ferrero" } }), signal: AbortSignal.timeout(120_000),});let run = await response.json();// 202: still going after 30 s. Ask again until it ends.while (response.status === 202) { await new Promise((done) => setTimeout(done, 2_000)); response = await fetch(`${api}/${run.id}`, { headers }); run = await response.json();}if (!response.ok) throw new Error(run.error.message);console.log(run.data);# Connect your agent to Fous once, over MCP (Streamable HTTP):# https://api.fous.com/mcp# Set FOUS_API_KEY first: create a key at https://app.fous.com/keys.# Claude Codeclaude mcp add \ --scope user \ --transport http fous https://api.fous.com/mcp \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Codexcodex mcp add fous \ --url https://api.fous.com/mcp \ --bearer-token-env-var FOUS_API_KEY# Cursor, VS Code, Windsurf, Cline and morenpx -y add-mcp https://api.fous.com/mcp -g -n fous \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Then ask your agent:# "Use Fous to run openfoodfacts.org/get_product# with {"product":"Nutella Ferrero"}"Over HTTP, the answer’s data holds the output. A run still going after 30 seconds answers 202 with its id: ask GET /v1/runs/{id} until it ends.
Schema
Input schema
{ "type": "object", "required": [ "product" ], "properties": { "product": { "type": "string", "description": "Product name with brand or barcode printed on the pack, for example Nutella Ferrero or 3017620422003." } }}Output schema
{ "type": "object", "required": [ "product_name", "brand", "quantity", "ingredients_text", "allergens", "nutri_score", "processing_level", "nutrition_per_100g", "nutrition_per_serving", "countries_sold_in", "photo_link", "open_food_facts_link", "barcode", "nova_number" ], "properties": { "brand": { "type": [ "string", "null" ], "description": "Brand or brands." }, "barcode": { "type": "string", "description": "Product barcode.", "x-fous-developer": true }, "quantity": { "type": [ "string", "null" ], "description": "Pack quantity as labeled." }, "allergens": { "type": "array", "items": { "type": "string" }, "description": "Allergens in words." }, "photo_link": { "type": [ "string", "null" ], "description": "Product photo link." }, "nova_number": { "type": [ "integer", "null" ], "description": "NOVA group number, 1 to 4.", "x-fous-developer": true }, "nutri_score": { "type": [ "string", "null" ], "description": "Nutri-Score letter A–E and its nutrition-quality meaning." }, "product_name": { "type": [ "string", "null" ], "description": "Name printed for the product." }, "ingredients_text": { "type": [ "string", "null" ], "description": "Ingredients, in English when available." }, "processing_level": { "type": [ "string", "null" ], "description": "NOVA processing level in words." }, "countries_sold_in": { "type": "array", "items": { "type": "string" }, "description": "Countries where the product is reported sold." }, "nutrition_per_100g": { "type": "object", "required": [ "energy_kcal", "fat_g", "saturated_fat_g", "carbohydrates_g", "sugars_g", "fibre_g", "protein_g", "salt_g" ], "properties": { "fat_g": { "type": [ "number", "null" ], "description": "Total fat in grams." }, "salt_g": { "type": [ "number", "null" ], "description": "Salt in grams." }, "fibre_g": { "type": [ "number", "null" ], "description": "Fibre in grams." }, "sugars_g": { "type": [ "number", "null" ], "description": "Sugars in grams." }, "protein_g": { "type": [ "number", "null" ], "description": "Protein in grams." }, "energy_kcal": { "type": [ "number", "null" ], "description": "Energy in kilocalories." }, "carbohydrates_g": { "type": [ "number", "null" ], "description": "Carbohydrates in grams." }, "saturated_fat_g": { "type": [ "number", "null" ], "description": "Saturated fat in grams." } }, "description": "Nutrients per 100 g or 100 ml, as recorded by the source.", "additionalProperties": false }, "open_food_facts_link": { "type": "string", "description": "Product page on Open Food Facts." }, "nutrition_per_serving": { "type": "object", "required": [ "energy_kcal", "fat_g", "saturated_fat_g", "carbohydrates_g", "sugars_g", "fibre_g", "protein_g", "salt_g" ], "properties": { "fat_g": { "type": [ "number", "null" ], "description": "Total fat in grams." }, "salt_g": { "type": [ "number", "null" ], "description": "Salt in grams." }, "fibre_g": { "type": [ "number", "null" ], "description": "Fibre in grams." }, "sugars_g": { "type": [ "number", "null" ], "description": "Sugars in grams." }, "protein_g": { "type": [ "number", "null" ], "description": "Protein in grams." }, "energy_kcal": { "type": [ "number", "null" ], "description": "Energy in kilocalories." }, "carbohydrates_g": { "type": [ "number", "null" ], "description": "Carbohydrates in grams." }, "saturated_fat_g": { "type": [ "number", "null" ], "description": "Saturated fat in grams." } }, "description": "Nutrients per serving, when available.", "additionalProperties": false } }}- Price
- 1 credit per completed run (1¢ with pay as you go); failed runs are free.
- Method
openfoodfacts.org/get_product- Returns
- product name, brand, quantity, ingredients, allergens, Nutri-Score, NOVA level, nutrition per 100 g and per serving, countries, photo, Open Food Facts link
Use it from your agent
Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method openfoodfacts.org/get_product with the inputs above.
Ask your agent
- What are the ingredients and allergens in the Nutella Ferrero 400 g jar?
- Look up barcode 3017620422003 and tell me its Nutri-Score and NOVA level.
- Is the Oreo Original biscuit pack from Mondelez safe for someone with a nut allergy?
- Show me the nutrition per 100 g and per serving for Coca-Cola Zero 330 ml can.
- Find the product with barcode 5000159484695 and list its countries of sale and a photo link.
See more
All Open Food Facts methodsSearches Open Food Facts packaged foods by name, optionally filtered by diet, country where sold and brand, ordered by popularity (most scanned first).
openfoodfacts.org/search_productsIdentifies a product by its 12- or 13-digit barcode and returns its details, recorded price range and store offers from UPCitemdb.
upcitemdb.com/get_product_by_barcodeGets details, price and availability for a Walmart product by name or product link, using Walmart's default location.
walmart.com/get_productFinds a Flipkart product from its name or link and returns its price, offers, seller, ratings, highlights, specifications, images and delivery estimate (for a PIN code when given).
flipkart.com/get_product_by_productGets a Product Hunt product profile by product name or Product Hunt link: tagline, description, website, topics, review rating, followers, the five most recent reviews, recent launches with day rank and upvotes, and alternatives.
producthunt.com/get_productGets details for an Amazon product, found by name or by link, in a chosen country store. Offer prices, delivery and variants may be missing when Amazon does not show them publicly.
amazon.com/get_productGets a B&H Photo product's details by name, product link, or B&H number. A name uses the best matching search result; details and prices reflect the public page.
bhphotovideo.com/get_productGets a Sephora US product's full details from its name (optionally narrowed by brand) or its Sephora product link: price, sizes and shades with stock, highlights, description, ingredients, usage, ratings and images.
sephora.com/get_product