Skip to main content
Glama
thesaaspreneur

MyFitnessPal MCP

mfp_create_custom_food

Create a private custom food in MyFitnessPal with complete macros and micronutrients, returning an ID to add to your diary.

Instructions

Create a private custom food in the user's MyFitnessPal account.

Fills the full nutrition panel MFP supports (macros, fats breakdown,
cholesterol, sodium, potassium, fiber, sugars, and the four %DV micros).
Uses the cookie-authenticated web endpoint, so no browser needs to be
running. Returns the new food's id, which mfp_add_food_to_diary accepts.

CARBS ARE NET (with the default country_code="NL"): pass net carbs in
`carbs`; MFP stores net_carbs as given and reports total = carbs + fiber.
Never pre-add fiber. Verified: carbs=42/fiber=8 stores 50/42 under "NL" but
42/34 with country_code omitted, so the field is load-bearing, not cosmetic.

To correct an existing food, prefer mfp_edit_food (edits in place via PATCH);
creating a corrected copy and deleting the old one also works.

Args:
    params: CreateCustomFoodInput (description, brand_name, serving_amount,
        serving_unit, calories + optional nutrients, public, response_format)

Returns:
    str: The created food's id, description and HTTP status

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Install Server

TDQS

A4.9/5.0
Behavior5/5

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

Annotations only supply readOnlyHint=false and idempotentHint=false, so the description carries the burden of explaining behavior. It adds meaningful detail: the tool writes to the user's MFP account, fills the full nutrition panel, returns the new food's id, and has a non-obvious net-carbs caveat verified with concrete examples. No contradiction with annotations.

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 front-loaded with the primary action, then covers nutrition scope, endpoint behavior, return value, the carb gotcha, and the alternative correction path. The length is justified by the complexity, and no sentence is filler.

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

Completeness5/5

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

Given the tool's complexity, the description covers auth requirements, return values, the relationship to sibling tools, and the most important parameter trap. It is complete enough for an agent to select and invoke the tool 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 nested schema already documents each field with units, so the description does not need to repeat them. The prose adds load-bearing semantics beyond the schema: default country_code='NL' means carbs are net, fiber must not be pre-added, and the field affects stored values materially. The Args listing is only a name list, but the critical parameter knowledge is present.

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 states a specific verb and resource: 'Create a private custom food in the user's MyFitnessPal account.' It also distinguishes itself from related tools by referencing mfp_add_food_to_diary and mfp_edit_food.

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?

It explicitly routes corrections to mfp_edit_food and explains that the returned id is accepted by mfp_add_food_to_diary. It also notes that the cookie-authenticated endpoint requires no running browser, giving the agent practical context for when this tool can be invoked.

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

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/thesaaspreneur/myfitnesspal-mcp'

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