nutrients-mcp
nutrients-mcp
Give your AI assistant the ability to analyze food images and look up nutrition data for any food — calories, macros, vitamins, minerals, allergens, and dietary flags in under 1 second — powered by TastyAPI. Much faster and more accurate than Gemini and GPT-4 Vision (4-10 seconds).
Requirements
Node.js 18+
A TastyAPI API key — get one at tastyapi.com/pricing
Related MCP server: TikTok Complete MCP Server
Quick Start
Claude Code
claude mcp add nutrients -- npx -y nutrients-mcpThen set your API key in the server's environment config:
TASTYAPI_KEY=YOUR_API_KEYClaude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"nutrients": {
"command": "npx",
"args": ["-y", "nutrients-mcp"],
"env": { "TASTYAPI_KEY": "YOUR_API_KEY" }
}
}
}Cursor / Windsurf
Add to your mcp.json:
{
"mcpServers": {
"nutrients": {
"command": "npx",
"args": ["-y", "nutrients-mcp"],
"env": { "TASTYAPI_KEY": "YOUR_API_KEY" }
}
}
}Tools
analyze_food_image
Fetches a food image from a public URL and returns a full nutritional breakdown.
Parameter | Type | Required | Description |
| string | yes | Public URL of a food image to analyze |
Example prompt:
"What are the macros in this meal? https://example.com/pasta.jpg"
Example output:
{
"food_name": "Pasta Bolognese",
"calories": 520,
"macros": {
"protein_g": 24,
"carbohydrates_g": 68,
"fat_g": 16,
"fiber_g": 4
},
"vitamins": { "vitamin_c_mg": 8, "vitamin_b12_mcg": 1.4 },
"minerals": { "iron_mg": 3.2, "calcium_mg": 60 },
"allergens": ["gluten", "dairy"],
"dietary": { "vegan": false, "vegetarian": false, "gluten_free": false }
}analyze_food
Returns a full nutritional breakdown for a food item by name or description. No image required.
Parameter | Type | Required | Description |
| string | yes | Name or description of the food (e.g. |
Example prompt:
"How many calories are in a large avocado?"
Example output:
{
"food_name": "Large Avocado",
"calories": 322,
"macros": {
"protein_g": 4,
"carbohydrates_g": 17,
"fat_g": 29,
"fiber_g": 13
},
"vitamins": { "vitamin_k_mcg": 42, "folate_mcg": 163 },
"minerals": { "potassium_mg": 975, "magnesium_mg": 58 },
"allergens": [],
"dietary": { "vegan": true, "vegetarian": true, "gluten_free": true }
}Pricing
$0.015 per request + $5/month base fee (usage-based)
Or choose a flat-rate plan: Monthly ($29/mo · 5k calls) or Professional ($69/mo · 15k calls)
See tastyapi.com/pricing for full details.
License
MIT — © EB Tech LLC
Available Tools
2 toolsanalyze_foodA
Get detailed nutritional information for a food item by name or description (no image needed). Returns calories, macros, vitamins, minerals, allergens, and dietary flags.
| Name | Required | Description | Default |
|---|---|---|---|
| food_name | Yes | Name or description of the food to analyze (e.g. "grilled chicken breast 200g", "large apple") |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It transparently lists the kinds of data returned (calories, macros, vitamins, minerals, allergens, dietary flags) and clarifies the input format. It does not mention potential limitations or error cases, but for a simple read-only tool, this is adequate.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, well-structured sentence that is front-loaded with the primary action and resource, then lists return types. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with one parameter, no output schema, and no annotations, the description is sufficient: it states the purpose, input format, and output contents. The sibling tool is recognizable from its name, and the description's contrast covers the main contextual need.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema has 100% coverage with a clear parameter description and examples. The tool description adds extra context by specifying that input can be a name or description and that no image is needed, reinforcing and slightly expanding on the schema's meaning.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: it retrieves detailed nutritional information for a food item based on a name or description. It also explicitly distinguishes itself from the sibling tool by adding '(no image needed)', making the purpose unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage context by contrasting with the image-based sibling ('no image needed'). However, it does not explicitly name the alternative tool or provide when-to-use/when-not-to-use guidance beyond that implied contrast.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
analyze_food_imageA
Analyze a food image URL and return detailed nutritional information including calories, macros, vitamins, minerals, allergens, and dietary flags.
| Name | Required | Description | Default |
|---|---|---|---|
| image_url | Yes | Public URL of a food image to analyze |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description must carry the full burden of behavioral transparency. It states what the tool returns, but it does not disclose potential side effects, error conditions (e.g., invalid URL, non-food image), or whether any external network requests are made. The description is adequate but not rich in behavioral detail.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, focused sentence that front-loads the main purpose and immediately lists expected outputs. Every word contributes to clarity, with no wasted or redundant content. It is an excellent example of concise tool documentation.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
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, no annotations), the description provides adequate context: it identifies the input and describes the output categories. It lacks explicit differentiation from the sibling tool, but this is more a usage-guideline gap than a completeness issue. The description is sufficiently complete for a straightforward analysis tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The single parameter 'image_url' is already well-documented in the schema with a clear description ('Public URL of a food image to analyze'). The tool description adds no additional semantic information beyond what the schema provides, so it remains at the baseline for a fully documented parameter.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: analyzing a food image URL and returning detailed nutritional information. It enumerates specific outputs (calories, macros, vitamins, minerals, allergens, dietary flags), making the purpose unambiguous. The resource (food image URL) distinguishes it from the sibling 'analyze_food', which likely handles non-image food data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage when the user has a food image URL, but it does not explicitly state when to use this tool versus the sibling 'analyze_food' or any alternatives. There are no clear exclusions or scenario-based guidance, so the usage context is only implied rather than explicitly articulated.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
Both tools analyze food and return similar nutritional data, but they are clearly distinguished by input type: one requires an image URL and the other a text name/description. The descriptions make this distinction explicit, so an agent should be able to select the correct tool without confusion.
The tools follow a consistent verb_noun pattern: 'analyze_food' and 'analyze_food_image'. The naming is predictable and clearly indicates a shared core function with a specific modifier for the image variant.
With only two tools, the server feels thin for the domain of nutritional analysis. While both tools are useful, the minimal count limits the server's overall utility and makes it borderline appropriate for its stated purpose.
The two tools cover the two primary input methods for analyzing a food item: image and text description. However, there are minor gaps, such as no batch analysis or retrieval of nutritional data by food ID, but the core workflow of analyzing a single food item is fully supported.
Maintenance
Related MCP Connectors
Spoonacular food API: recipes, nutrition, ingredients, meal plans. Free 150/day.
Log what you ate by talking to your AI assistant — calories and macros, completely free.
Food logging, nutrition summaries, and meal photo calorie and macro estimates.
Food and nutrition data: search, macros, and comparisons
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceConnect engineering metrics, DORA performance, deploy risk scoring, and PR health to any AI assistant. Score PRs for deployment risk using a 36-signal model, query team health, incidents, coverage, and more.MIT
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to download TikTok videos without watermarks, analyze creator metrics and audience insights, track trending content and hashtags, and search videos, users, and sounds through RapidAPI integration.
- AlicenseAqualityDmaintenanceEnables AI assistants to generate 3D models, textures, and images via the Meshy API using natural language, supporting text-to-3D, image-to-3D, remeshing, retexturing, rigging, and animation workflows.36601MIT
- AlicenseAqualityDmaintenanceEnables AI agents to analyze images, extract text, compare images, and analyze video through any OpenAI-compatible vision model.411920MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/ericblair1903/nutrients-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server