Skip to main content
Glama

Get nutrient values

get_nutrients
Read-onlyIdempotent

Retrieve all ~60 nutrient values per 100 g for one food, or filter by codes/names. Unmatched filter terms appear in the response.

Instructions

Get nutrient values per 100 g for one food. Returns all ~60 nutrients (vitamins, minerals, fatty acids, sugars, energy) unless you pass a nutrients filter. Unknown filter terms are listed in 'unmatched'.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
numberYesFood number from search_foods (livsmedelsnummer).
languageNoLanguage for food and nutrient names: 'en' (English) or 'sv' (Swedish). Defaults to the server setting.
nutrientsNoNutrients to include, by code (e.g. 'PROT', 'ENERC_KCAL', 'VITD') or name fragment (e.g. 'iron', 'vitamin b'). Omit for the default set.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already cover read-only/idempotent safety. The description adds two behavioral details: the default return set ('all ~60 nutrients') and how unknown filter terms are handled ('listed in unmatched'). This gives an agent foresight into failure modes and response shape without repetition.

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?

Two sentences, zero waste. Purpose is front-loaded, followed by default behavioral scope, then the edge case. Every word earns its place.

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?

For a single-food nutrient query, the description covers the main behavior, the scaling (per 100 g), default nutrient set, and the unmatched-field edge case. Since there is no output schema, a little more return-structure detail would help, but the essential context is present and adequate.

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

Parameters3/5

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

Schema description coverage is 100%, so the baseline is 3. The description only lightly references the nutrients filter and adds no syntax or code details beyond what the schema already provides. No extra semantic value.

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?

States a specific verb and resource: 'Get nutrient values per 100 g for one food.' The 'one food' scope differentiates it from compare_foods and calculate_recipe_nutrition, and the 'per 100 g' detail adds precision. An agent can tell it apart from siblings without opening schemas.

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

Usage Guidelines3/5

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

The description implies a clear use case (single food nutrient lookup) but never explicitly names alternatives or conditions for when to use those instead. No mention of search_foods as a prerequisite or compare_foods for multiple items. Usage is inferred, not directed.

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