Product & Barcode Intelligence · Live API Slug: openfoodfacts_barcode_lookup 0-LLM Deterministic

OpenFoodFacts Barcode Lookup MCP Server

Grocery aggregators, nutrition copilots, and CPG catalog teams need structured product titles, brands, categories, and Nutri-Score grades from raw EAN-8, UPC-A, EAN-13, or GTIN-14 barcodes without maintaining fragile scrapers.

5-Second Try-Now Console Connect via /mcp FastMesh SuperBus

How It Works & Live Probe Telemetry

This organ queries the OpenFoodFacts API v2 endpoint over HTTPS with strict numeric digit validation before any outbound request leaves the server. During live probe testing on barcode 3017620422003, the endpoint returned HTTP 200 in 7,745.42 ms with product_name 'Nutella' and brands 'Ferrero, Nutella'. Crucially, OpenFoodFacts returns HTTP 200 even for non-existent barcodes such as 0000000000000 alongside JSON status: 0 ('no code or invalid code'). Our anti-fake-200 gate inspects status == 1 and non-empty product_name before marking a hit billable, so misses cost strictly $0.00.

Verified Endpoint & Billing Contract

MCP Tool Nameopenfoodfacts_barcode_lookup
Subdomain & Modeproduct_barcode · live_public_api
REST EndpointPOST https://devour-com.fastmesh.dev/v1/organs/openfoodfacts_barcode_lookup/invoke
MCP EndpointPOST https://devour-com.fastmesh.dev/mcp (also mounted on https://mcp.fastmesh.dev/mcp)
Verified Probe Latency7745.42 ms (HTTP 200, verified 2026-12-02T10:48:11Z)
Archive Cache TTL14 days (1209600s) cross-tenant verified-hit cache
Empty / Error RuleCharge $0.00 when barcode fails digit check, HTTP status != 200, JSON status == 0 ('product not found' fake-200), or product_name is empty.
Plans & PrivacyStarter $19/mo · Pro $79/mo · Scale $249/mo · Zero trajectory resale

Production Use Cases

ScenarioTrigger InputDeterministic Output Value
Retail POS Catalog HydrationNew SKU barcode scanned at receiving dockReturns canonical brand, category tree, and Nutri-Score in one JSON block
Allergen & Nutrition CopilotConsumer dietary assistant checks packaged snackProvides structured product metadata without scraping HTML storefronts
Marketplace Listing HygieneSeller uploads 13-digit EAN with missing brandSeparates genuine OpenFoodFacts hits from status=0 empty records at $0 cost

MCP JSON-RPC 2.0 & REST Invocation Examples

Call via MCP tools/call on https://devour-com.fastmesh.dev/mcp:

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfoodfacts_barcode_lookup",
    "arguments": {
      "barcode": "3017620422003"
    }
  }
}

Or invoke directly via REST (POST /v1/organs/openfoodfacts_barcode_lookup/invoke):

curl -sS -X POST https://devour-com.fastmesh.dev/v1/organs/openfoodfacts_barcode_lookup/invoke \
  -H 'Content-Type: application/json' \
  -d '{"input": {"barcode": "3017620422003"}}'

Verified structured JSON response:

{
  "ok": true,
  "barcode": "3017620422003",
  "product_name": "Nutella",
  "brands": "Ferrero, Nutella",
  "categories": "Breakfasts, Spreads, Sweet spreads, Hazelnut spreads",
  "nutriscore_grade": "e",
  "billable_usd": "0.01"
}

Strict Input Schema

{
  "type": "object",
  "properties": {
    "barcode": {
      "type": "string",
      "pattern": "^[0-9]{8,14}$",
      "description": "EAN-8, UPC-A, EAN-13, or GTIN-14 numeric barcode."
    }
  },
  "required": [
    "barcode"
  ],
  "additionalProperties": false
}

Frequently Asked Questions

How does the OpenFoodFacts MCP server handle invalid or missing barcodes?

Any non-numeric code, malformed length outside 8 to 14 digits, or OpenFoodFacts JSON payload with status=0 is intercepted by the anti-fake-200 layer and billed at $0.00.

How long are verified food barcode records cached?

Verified non-empty hits are retained in the cross-tenant archive cache for 14 days (1,209,600 seconds), eliminating repeat upstream latency on popular CPG SKUs.

Related Commerce & Marketing MCP Tools