Skip to main content
Glama
borgels

mcp-server-fooddata-dk

by borgels

Look Up Food by Barcode

fooddata_get_by_barcode
Read-onlyIdempotent

Look up packaged food products by barcode (EAN) to get nutrition data. If the Danish barcode isn't found, fall back to searching by product name.

Instructions

Look up a packaged product by its barcode (EAN) in Open Food Facts. Danish barcode coverage is good but incomplete — if nothing is found, fall back to fooddata_search by name.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
barcodeYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so the safety profile is covered. The description adds behavioral context beyond those annotations: it notes that Danish barcode coverage is good but incomplete, implying occasional empty results, and it communicates the fallback behavior. This is useful context that enriches what the annotations already provide, though it doesn't discuss rate limits or auth requirements, which are likely not applicable here.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, with no fluff. The first sentence states the primary use case; the second adds essential fallback guidance. Front-loaded and efficient, every word contributes to selection and invocation.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the simplicity of the tool (one parameter, no output schema), the description is complete enough: it explains what the tool does, when to use it, and what to do if it fails. The fallback to fooddata_search covers a critical edge case. It doesn't detail the exact return format, but for a lookup tool with an open-world hint, this is acceptable. Overall, it provides sufficient context for an agent to use it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% description coverage, so the description must compensate. It does so by clarifying the 'barcode' parameter is an EAN and tying it directly to the tool's purpose. The schema already enforces numeric string with minLength 6, and the description adds the semantic meaning of 'EAN' without redundancy. This is sufficient for a simple single-parameter tool.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: to look up a packaged product by its barcode (EAN) in Open Food Facts. It uses a specific verb ('look up') and resource ('packaged product by barcode'), which distinguishes it from sibling tools like fooddata_search (by name) and fooddata_get_food (likely by internal ID). The explicit mention of 'barcode (EAN)' leaves no ambiguity about what the tool does.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit when-to-use guidance and a fallback: 'if nothing is found, fall back to fooddata_search by name.' This tells the agent exactly when to use this tool and what to do if it fails, and it names the alternative tool (fooddata_search). This is a model of clear usage instruction.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/borgels/mcp-server-fooddata-dk'

If you have feedback or need assistance with the MCP directory API, please join our Discord server