Skip to main content
Glama
asachs01
by asachs01

nutrition-mcp

USDA FoodData Central MCP server for nutrition lookup, meal logging, and daily macro tracking.

Setup

  1. Get a free API key at https://fdc.nal.usda.gov/api-key-signup

  2. Set USDA_API_KEY environment variable (or it falls back to DEMO_KEY)

cp .env.example .env
# Edit .env with your key

Related MCP server: nutrition-mcp

Usage

node src/server.js  # stdio MCP server

Tools

nutrition

Action

Description

Key Params

search

Search foods by name

query, dataType, pageSize

get

Full nutrition details

fdcId

compare

Side-by-side macro comparison

fdcIds (array)

meal_log

Action

Description

Key Params

log

Log a food eaten

fdcId, servings, mealType, date

list

List entries for a date

date, mealType

delete

Remove an entry

entryId

daily_summary

Macro totals for a day

date

weekly_summary

Weekly averages

weekOf

targets

Action

Description

Key Params

set

Set daily macro targets

calories, protein, carbs, fat, fiber

get

View current targets

progress

Progress vs targets

date

Architecture

src/
  server.js          — MCP stdio server
  usda-client.js     — USDA API client with 24h cache
  meal-log.js        — Local meal log storage (~/.nutrition-mcp/logs/)
  targets.js         — Macro targets storage (~/.nutrition-mcp/targets.json)
  tools/
    nutrition.js     — nutrition tool handler
    meal-log.js      — meal_log tool handler
    targets.js       — targets tool handler
test/
  server.test.js     — Unit tests

Testing

npm test

License

MIT © Aaron Sachs

A
license - permissive license
-
quality - not tested
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    A
    quality
    A
    maintenance
    A local-first nutrition MCP server for food search, barcode lookup, meal estimation, intake logging, hydration, and nutrition coaching workflows.
    46
    262
    8
    MIT
  • F
    license
    -
    quality
    B
    maintenance
    Local-first nutrition tracker MCP server for Hermes, enabling food, alias, recipe, and meal log management with SQLite persistence.
  • A
    license
    -
    quality
    B
    maintenance
    Tracks macros and logs meals via plain language by exposing a local USDA food database as an MCP server.
    MIT

View all related MCP servers

Related MCP Connectors

View all MCP Connectors

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/asachs01/nutrition-mcp'

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