pp-myfitnesspal

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

MyFitnessPal — Printing Press CLI

MyFitnessPal — Printing Press CLI

Prerequisites: Install the CLI

前提条件:安装CLI

This skill drives the
myfitnesspal-pp-cli
binary. You must verify the CLI is installed before invoking any command from this skill. If it is missing, install it first:
  1. Install via the Printing Press installer:
    bash
    npx -y @mvanhorn/printing-press install myfitnesspal --cli-only
  2. Verify:
    myfitnesspal-pp-cli --version
  3. Ensure
    $GOPATH/bin
    (or
    $HOME/go/bin
    ) is on
    $PATH
    .
If the
npx
install fails (no Node, offline, etc.), fall back to a direct Go install (requires Go 1.26.3 or newer):
bash
go install github.com/mvanhorn/printing-press-library/library/other/myfitnesspal/cmd/myfitnesspal-pp-cli@latest
If
--version
reports "command not found" after install, the install step did not put the binary on
$PATH
. Do not proceed with skill commands until verification succeeds.
MyFitnessPal closed their API, gates per-food export behind premium, and ships per-meal rows even there. This CLI imports your browser session, syncs your diary to local SQLite, and answers questions the official UI never can: which 5 foods drove 80% of your protein this quarter, what's your weekly weight slope vs your deficit, what changed since last sync. Built with agent-native output (
--json
,
--select
,
context
) so Claude can reason over your last 14 days in one tool call.
本技能基于
myfitnesspal-pp-cli
二进制文件运行。在调用本技能的任何命令前,你必须确认CLI已安装。如果未安装,请先执行以下步骤:
  1. 通过Printing Press安装器安装:
    bash
    npx -y @mvanhorn/printing-press install myfitnesspal --cli-only
  2. 验证安装:
    myfitnesspal-pp-cli --version
  3. 确保
    $GOPATH/bin
    (或
    $HOME/go/bin
    )已添加到
    $PATH
    环境变量中。
如果
npx
安装失败(如无Node环境、离线等),可改用Go直接安装(要求Go 1.26.3或更高版本):
bash
go install github.com/mvanhorn/printing-press-library/library/other/myfitnesspal/cmd/myfitnesspal-pp-cli@latest
如果安装后执行
--version
提示“command not found”,说明安装程序未将二进制文件添加到
$PATH
中。请在验证成功前不要执行技能命令。
MyFitnessPal已关闭公开API,且仅向付费用户提供按餐导出的功能,即便如此导出的也是按餐汇总的数据。本CLI可导入你的浏览器会话,将饮食日记同步到本地SQLite数据库,并能解答官方UI无法回答的问题:比如过去三个月中哪5种食物贡献了你80%的蛋白质、你的每周体重变化趋势与热量缺口的关系、上次同步后数据有哪些变化等。它专为Agent设计输出格式(
--json
--select
context
命令),让Claude可通过一次工具调用就能分析你过去14天的饮食数据。

When to Use This CLI

何时使用本CLI

Reach for this CLI when an agent needs to reason over a user's actual eating, exercise, or weight history — especially across windows longer than today. The local SQLite store + agent-shaped
context
command means one tool call replaces the back-and-forth of pasting yesterday's diary into the chat. Use it for nutrition coaching, deficit calibration, macro analysis, recall questions ('every time I logged X'), and anywhere the official MFP UI's per-meal rollup blocks the question.
当Agent需要分析用户实际的饮食、运动或体重历史时,尤其是时间跨度超过一天的情况,可使用本CLI。本地SQLite存储+适配Agent的
context
命令,让Agent无需反复让用户粘贴饮食日记,一次工具调用就能获取所需信息。适用于营养指导、热量缺口校准、宏量营养素分析、饮食记录查询(如“我每次记录X食物的情况”),以及官方MFP UI按餐汇总数据无法满足需求的场景。

Unique Capabilities

独特功能

These capabilities aren't available in any other tool for this API.
这些功能是其他同类工具所不具备的。

Local state that compounds

可累积的本地状态

  • export csv
    — Export your food diary to CSV with one row per logged food, not per meal. Premium MFP only ships per-meal CSVs.
    Reach for this when an agent needs the user's full eating history at food granularity for analysis, training, or long-form coaching memory.
    bash
    myfitnesspal-pp-cli export csv --from 2026-01-01 --to 2026-05-08 --out diary.csv
  • analytics top-foods
    — Pareto query: which N foods drove X% of your protein/carbs/fat/fiber/sugar/calories over a window?
    Use when an agent is helping the user understand what's actually driving a macro target, not what they think is.
    bash
    myfitnesspal-pp-cli analytics top-foods --nutrient protein --days 60 --cumulative-percent 80 --json
  • find
    — Full-text search across every diary entry and food in the local store. Returns date, meal, servings, calories per match.
    Use when an agent needs to recall every time the user logged a specific food without scrolling through months of diary.
    bash
    myfitnesspal-pp-cli find --food "Chipotle Bowl" --from 2026-01-01 --json
  • analytics streak
    — Longest run of consecutive days where calorie totals fall within ±tolerance of your goal.
    Use when the user asks how their adherence is trending — answer arrives without subjective interpretation.
    bash
    myfitnesspal-pp-cli analytics streak --days 60 --tolerance 0.05 --json
  • export csv
    — 将饮食日记导出为CSV,每条记录对应一份单独的食物,而非按餐汇总。MyFitnessPal付费版仅提供按餐导出的CSV。
    当Agent需要获取用户完整的、按单份食物粒度的饮食历史用于分析、训练或长期指导记忆时,可使用此命令。
    bash
    myfitnesspal-pp-cli export csv --from 2026-01-01 --to 2026-05-08 --out diary.csv
  • analytics top-foods
    — 帕累托查询:在指定时间段内,哪N种食物贡献了你X%的蛋白质/碳水/脂肪/膳食纤维/糖分/热量?
    当Agent帮助用户了解实际驱动宏量营养素目标的食物(而非用户自认为的食物)时,可使用此命令。
    bash
    myfitnesspal-pp-cli analytics top-foods --nutrient protein --days 60 --cumulative-percent 80 --json
  • find
    — 在本地存储的所有饮食记录和食物中进行全文搜索,返回匹配结果的日期、餐次、份量、热量。
    当Agent需要查询用户每次记录某特定食物的情况,无需让用户手动翻阅数月的饮食日记时,可使用此命令。
    bash
    myfitnesspal-pp-cli find --food "Chipotle Bowl" --from 2026-01-01 --json
  • analytics streak
    — 查询连续天数最长的、每日热量摄入在目标值±公差范围内的记录。
    当用户询问自己的饮食坚持趋势时,可使用此命令给出客观答案,无需主观解读。
    bash
    myfitnesspal-pp-cli analytics streak --days 60 --tolerance 0.05 --json

Agent-native plumbing

Agent原生适配功能

  • context
    — Single-call snapshot of the last N days: diary totals, weight trend, current goals, recent foods, macro deltas — sized for an agent context window.
    First call any agent should make before reasoning about a user's nutrition — gives the full picture in one shot.
    bash
    myfitnesspal-pp-cli context --days 14 --json
  • context
    — 一次调用获取最近N天的快照:饮食总览、体重趋势、当前目标、近期食物、宏量营养素差值——数据大小适配Agent的上下文窗口。
    Agent在分析用户营养情况前应首先调用此命令,一次获取完整的信息全貌。
    bash
    myfitnesspal-pp-cli context --days 14 --json

Command Reference

命令参考

api-user — Authenticated user record on the v2 API (preferences, paid subs, profiles).
  • myfitnesspal-pp-cli api-user
    — Get the v2 user record (units, goals preferences, paid subs, profiles).
diary — Daily food diary (per-meal entries with full nutrient panel).
  • myfitnesspal-pp-cli diary get-day
    — Get one day's food diary as scraped HTML (legacy surface python-myfitnesspal uses).
  • myfitnesspal-pp-cli diary load-recent
    — Load the recent-foods quick-pick list for a meal.
exercise — Cardio and strength exercises logged on a given day.
  • myfitnesspal-pp-cli exercise
    — Get one day's exercise log (cardio + strength) as scraped HTML.
food — Search the public food database, view food details, log custom foods.
  • myfitnesspal-pp-cli food details
    — Get full nutrient panel for a single food by MFP food id.
  • myfitnesspal-pp-cli food search
    — Search the food database.
  • myfitnesspal-pp-cli food suggested-servings
    — Get common serving-size suggestions for a food (powers the '1 cup / 100g / medium' picker).
goals — Daily calorie / macro / water / weight goals.
  • myfitnesspal-pp-cli goals
    — Get your current daily goals (calorie target, macro split, water target) as scraped HTML.
measurement — Weight, body fat, and other body measurements (time series).
  • myfitnesspal-pp-cli measurement get-range
    — Get a date range of values for one measurement type as scraped HTML.
  • myfitnesspal-pp-cli measurement types
    — List the measurement types defined for your account (Weight, BodyFat, Neck, Waist, Hips, plus custom).
note — Free-text notes attached to a day's food or exercise diary.
  • myfitnesspal-pp-cli note
    — Get the food note for a single day.
reports — Aggregated time-series reports (any nutrient or weight as a date->value series).
  • myfitnesspal-pp-cli reports
    — Get a time-series report (e.g. nutrition/Net%20Calories/30 returns the last 30 days of net calories).
user — Authenticated user account info, units, and preferences.
  • myfitnesspal-pp-cli user auth-token
    — Bootstrap a v2 bearer token from your session cookies.
  • myfitnesspal-pp-cli user top-foods-server
    — Get your top-logged foods over a date range, computed server-side (powers the 'your most-eaten' insights).
water — Daily water intake tracking.
  • myfitnesspal-pp-cli water
    — Get water intake for a single day.
api-user — v2 API上的已认证用户记录(偏好设置、付费订阅、个人资料)。
  • myfitnesspal-pp-cli api-user
    — 获取v2用户记录(单位、目标偏好、付费订阅、个人资料)。
diary — 每日饮食日记(按餐记录,包含完整营养成分表)。
  • myfitnesspal-pp-cli diary get-day
    — 获取某一天的饮食日记(以抓取的HTML格式呈现,为python-myfitnesspal使用的遗留格式)。
  • myfitnesspal-pp-cli diary load-recent
    — 加载某一餐的近期食物快速选择列表。
exercise — 某一天记录的有氧和力量训练运动。
  • myfitnesspal-pp-cli exercise
    — 获取某一天的运动记录(有氧+力量,以抓取的HTML格式呈现)。
food — 搜索公共食物数据库、查看食物详情、记录自定义食物。
  • myfitnesspal-pp-cli food details
    — 通过MFP食物ID获取单份食物的完整营养成分表。
  • myfitnesspal-pp-cli food search
    — 搜索食物数据库。
  • myfitnesspal-pp-cli food suggested-servings
    — 获取某食物的常见份量建议(支持“1杯/100克/中等大小”选择器)。
goals — 每日热量/宏量营养素/饮水量/体重目标。
  • myfitnesspal-pp-cli goals
    — 获取当前每日目标(热量目标、宏量营养素分配、饮水量目标,以抓取的HTML格式呈现)。
measurement — 体重、体脂及其他身体测量数据(时间序列)。
  • myfitnesspal-pp-cli measurement get-range
    — 获取某一测量类型在指定日期范围内的数据(以抓取的HTML格式呈现)。
  • myfitnesspal-pp-cli measurement types
    — 列出你的账户中定义的测量类型(体重、体脂、颈围、腰围、臀围及自定义类型)。
note — 附加在每日饮食或运动日记上的自由文本备注。
  • myfitnesspal-pp-cli note
    — 获取某一天的饮食备注。
reports — 聚合时间序列报告(任何营养素或体重的日期->值序列)。
  • myfitnesspal-pp-cli reports
    — 获取时间序列报告(例如nutrition/Net%20Calories/30返回过去30天的净热量数据)。
user — 已认证用户账户信息、单位及偏好设置。
  • myfitnesspal-pp-cli user auth-token
    — 从会话Cookie中生成v2 Bearer令牌。
  • myfitnesspal-pp-cli user top-foods-server
    — 获取指定日期范围内你记录最多的食物(由服务器计算,为“你最常吃的食物”洞察功能提供数据)。
water — 每日饮水量追踪。
  • myfitnesspal-pp-cli water
    — 获取某一天的饮水量。

Finding the right command

查找合适的命令

When you know what you want to do but not which command does it, ask the CLI directly:
bash
myfitnesspal-pp-cli which "<capability in your own words>"
which
resolves a natural-language capability query to the best matching command from this CLI's curated feature index. Exit code
0
means at least one match; exit code
2
means no confident match — fall back to
--help
or use a narrower query.
当你知道要做什么但不知道对应的命令时,可直接询问CLI:
bash
myfitnesspal-pp-cli which "<用你自己的话描述功能>"
which
命令会将自然语言的功能查询解析为CLI中最匹配的命令。退出码
0
表示至少找到一个匹配项;退出码
2
表示没有找到明确匹配项——此时可使用
--help
或缩小查询范围。

Recipes

使用示例

Build agent context for a coaching question

为指导问题构建Agent上下文

bash
myfitnesspal-pp-cli context --days 30 --json --select diary_totals,weight_trend,goals
One tool call gives the agent everything it needs to answer 'should I cut more this week?' without back-and-forth pasting.
bash
myfitnesspal-pp-cli context --days 30 --json --select diary_totals,weight_trend,goals
一次工具调用就能让Agent获取回答“我这周应该减少更多热量摄入吗?”所需的全部信息,无需反复让用户粘贴数据。

Find every time you logged a food

查询每次记录某食物的情况

bash
myfitnesspal-pp-cli find --food "Greek yogurt" --from 2026-01-01 --json --select date,meal,servings,calories
Local FTS over your synced diary; instant answer to recall questions the MFP web UI requires scrolling for.
bash
myfitnesspal-pp-cli find --food "Greek yogurt" --from 2026-01-01 --json --select date,meal,servings,calories
在同步后的本地日记中进行全文搜索,可立即回答MFP网页UI需要手动翻阅才能找到的回忆类问题。

Per-food CSV for a quarter

导出一季度的按单份食物CSV

bash
myfitnesspal-pp-cli export csv --from 2026-01-01 --to 2026-03-31 --out q1-2026.csv
One row per food entry with full nutrients — the export premium MFP doesn't deliver.
bash
myfitnesspal-pp-cli export csv --from 2026-01-01 --to 2026-03-31 --out q1-2026.csv
每条记录对应一份食物,包含完整营养成分——这是MyFitnessPal付费版都无法提供的导出功能。

Top foods driving a macro

查询驱动宏量营养素的主要食物

bash
myfitnesspal-pp-cli analytics top-foods --nutrient protein --days 60 --cumulative-percent 0.8 --json
Pareto query over the local diary: which foods drove most of your protein over the last 60 days.
bash
myfitnesspal-pp-cli analytics top-foods --nutrient protein --days 60 --cumulative-percent 0.8 --json
对本地日记执行帕累托查询:找出过去60天中贡献了你大部分蛋白质的食物。

Adherence streak

饮食坚持记录

bash
myfitnesspal-pp-cli analytics streak --days 60 --tolerance 0.05 --json
Longest run of days inside ±5% of your calorie goal. Goal value is read from the most recent
goal_snapshot
synced into the local store; pass
--goal-calories <value>
to override.
bash
myfitnesspal-pp-cli analytics streak --days 60 --tolerance 0.05 --json
查询连续天数最长的、每日热量摄入在目标值±5%范围内的记录。目标值从同步到本地存储的最新
goal_snapshot
中读取;可通过
--goal-calories <value>
参数手动指定目标值。

Auth Setup

认证设置

MyFitnessPal closed their public API. This CLI uses your logged-in browser session — log in to myfitnesspal.com in Chrome, then run
myfitnesspal-pp-cli auth login --chrome
. Cookies are read from the .myfitnesspal.com domain. Sessions usually last 7-30 days; when they expire, log in again in Chrome and re-run
auth login --chrome
.
Run
myfitnesspal-pp-cli doctor
to verify setup.
MyFitnessPal已关闭公开API。本CLI使用你已登录的浏览器会话——在Chrome中登录myfitnesspal.com,然后执行
myfitnesspal-pp-cli auth login --chrome
。Cookie从.myfitnesspal.com域名读取。会话通常持续7-30天;过期后,在Chrome中重新登录并再次执行
auth login --chrome
即可。
执行
myfitnesspal-pp-cli doctor
验证设置是否正确。

Agent Mode

Agent模式

Add
--agent
to any command. Expands to:
--json --compact --no-input --no-color --yes
.
  • Pipeable — JSON on stdout, errors on stderr
  • Filterable
    --select
    keeps a subset of fields. Dotted paths descend into nested structures; arrays traverse element-wise. Critical for keeping context small on verbose APIs:
    bash
    myfitnesspal-pp-cli api-user --user-id 550e8400-e29b-41d4-a716-446655440000 --agent --select id,name,status
  • Previewable
    --dry-run
    shows the request without sending
  • Offline-friendly — sync/search commands can use the local SQLite store when available
  • Non-interactive — never prompts, every input is a flag
  • Explicit retries — use
    --idempotent
    only when an already-existing create should count as success
在任何命令后添加
--agent
参数,等效于添加:
--json --compact --no-input --no-color --yes
  • 可管道传输 — JSON输出到标准输出,错误信息输出到标准错误
  • 可过滤
    --select
    参数可保留指定字段。点路径可深入嵌套结构;数组可遍历元素。这对于在冗长API中缩小上下文大小至关重要:
    bash
    myfitnesspal-pp-cli api-user --user-id 550e8400-e29b-41d4-a716-446655440000 --agent --select id,name,status
  • 可预览
    --dry-run
    参数可显示请求内容但不发送
  • 离线友好 — 同步/搜索命令可在本地SQLite存储可用时使用本地数据
  • 非交互式 — 从不弹出提示,所有输入均通过参数传递
  • 显式重试 — 仅当已存在的创建操作应被视为成功时,使用
    --idempotent
    参数

Response envelope

响应包

Commands that read from the local store or the API wrap output in a provenance envelope:
json
{
  "meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
  "results": <data>
}
Parse
.results
for data and
.meta.source
to know whether it's live or local. A human-readable
N results (live)
summary is printed to stderr only when stdout is a terminal — piped/agent consumers get pure JSON on stdout.
从本地存储或API读取数据的命令会将输出包装在来源信息包中:
json
{
  "meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
  "results": <data>
}
解析
.results
获取数据,通过
.meta.source
判断数据是实时的还是本地的。仅当标准输出为终端时,才会在标准错误中打印人类可读的
N results (live)
摘要;管道/Agent消费者仅会在标准输出获取纯JSON。

Agent Feedback

Agent反馈

When you (or the agent) notice something off about this CLI, record it:
myfitnesspal-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
myfitnesspal-pp-cli feedback --stdin < notes.txt
myfitnesspal-pp-cli feedback list --json --limit 10
Entries are stored locally at
~/.myfitnesspal-pp-cli/feedback.jsonl
. They are never POSTed unless
MYFITNESSPAL_FEEDBACK_ENDPOINT
is set AND either
--send
is passed or
MYFITNESSPAL_FEEDBACK_AUTO_SEND=true
. Default behavior is local-only.
Write what surprised you, not a bug report. Short, specific, one line: that is the part that compounds.
当你(或Agent)发现本CLI存在问题时,可记录反馈:
myfitnesspal-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
myfitnesspal-pp-cli feedback --stdin < notes.txt
myfitnesspal-pp-cli feedback list --json --limit 10
反馈条目存储在本地
~/.myfitnesspal-pp-cli/feedback.jsonl
文件中。除非设置了
MYFITNESSPAL_FEEDBACK_ENDPOINT
且传递了
--send
参数或设置
MYFITNESSPAL_FEEDBACK_AUTO_SEND=true
,否则反馈不会被发送。默认行为仅存储在本地。
请记录让你感到意外的内容,而非正式的错误报告。简短、具体、一句话即可:这样的反馈才最有价值。

Output Delivery

输出交付

Every command accepts
--deliver <sink>
. The output goes to the named sink in addition to (or instead of) stdout, so agents can route command results without hand-piping. Three sinks are supported:
SinkEffect
stdout
Default; write to stdout only
file:<path>
Atomically write output to
<path>
(tmp + rename)
webhook:<url>
POST the output body to the URL (
application/json
or
application/x-ndjson
when
--compact
)
Unknown schemes are refused with a structured error naming the supported set. Webhook failures return non-zero and log the URL + HTTP status on stderr.
所有命令均支持
--deliver <sink>
参数。输出会发送到指定的接收端,同时(或替代)输出到标准输出,让Agent无需手动管道即可路由命令结果。支持三种接收端:
接收端效果
stdout
默认值;仅输出到标准输出
file:<path>
原子性地将输出写入
<path>
(先写入临时文件再重命名)
webhook:<url>
将输出体POST到指定URL(当使用
--compact
时为
application/json
application/x-ndjson
格式)
不支持的协议会返回结构化错误,并列出支持的协议类型。Webhook失败会返回非零退出码,并在标准错误中记录URL和HTTP状态码。

Named Profiles

命名配置文件

A profile is a saved set of flag values, reused across invocations. Use it when a scheduled agent calls the same command every run with the same configuration - HeyGen's "Beacon" pattern.
myfitnesspal-pp-cli profile save briefing --json
myfitnesspal-pp-cli --profile briefing api-user --user-id 550e8400-e29b-41d4-a716-446655440000
myfitnesspal-pp-cli profile list --json
myfitnesspal-pp-cli profile show briefing
myfitnesspal-pp-cli profile delete briefing --yes
Explicit flags always win over profile values; profile values win over defaults.
agent-context
lists all available profiles under
available_profiles
so introspecting agents discover them at runtime.
配置文件是一组保存的参数值,可在多次调用中复用。适用于定时Agent每次运行都使用相同配置调用同一命令的场景(即HeyGen的“Beacon”模式)。
myfitnesspal-pp-cli profile save briefing --json
myfitnesspal-pp-cli --profile briefing api-user --user-id 550e8400-e29b-41d4-a716-446655440000
myfitnesspal-pp-cli profile list --json
myfitnesspal-pp-cli profile show briefing
myfitnesspal-pp-cli profile delete briefing --yes
显式参数始终优先于配置文件中的值;配置文件中的值优先于默认值。
agent-context
命令会在
available_profiles
下列出所有可用配置文件,让Agent可在运行时自动发现它们。

Exit Codes

退出码

CodeMeaning
0Success
2Usage error (wrong arguments)
3Resource not found
4Authentication required
5API error (upstream issue)
7Rate limited (wait and retry)
10Config error
代码含义
0成功
2使用错误(参数错误)
3资源未找到
4需要认证
5API错误(上游问题)
7速率限制(请等待后重试)
10配置错误

Argument Parsing

参数解析

Parse
$ARGUMENTS
:
  1. Empty,
    help
    , or
    --help
    → show
    myfitnesspal-pp-cli --help
    output
  2. Starts with
    install
    → ends with
    mcp
    → MCP installation; otherwise → see Prerequisites above
  3. Anything else → Direct Use (execute as CLI command with
    --agent
    )
解析
$ARGUMENTS
的规则:
  1. 为空、
    help
    --help
    → 显示
    myfitnesspal-pp-cli --help
    输出
  2. install
    开头
    → 若结尾为
    mcp
    → 安装MCP服务器;否则 → 参考上方前提条件中的安装步骤
  3. 其他情况 → 直接使用(添加
    --agent
    参数执行CLI命令)

MCP Server Installation

MCP服务器安装

  1. Install the MCP server:
    bash
    go install github.com/mvanhorn/printing-press-library/library/other/myfitnesspal/cmd/myfitnesspal-pp-mcp@latest
  2. Register with Claude Code:
    bash
    claude mcp add myfitnesspal-pp-mcp -- myfitnesspal-pp-mcp
  3. Verify:
    claude mcp list
  1. 安装MCP服务器:
    bash
    go install github.com/mvanhorn/printing-press-library/library/other/myfitnesspal/cmd/myfitnesspal-pp-mcp@latest
  2. 注册到Claude Code:
    bash
    claude mcp add myfitnesspal-pp-mcp -- myfitnesspal-pp-mcp
  3. 验证:
    claude mcp list

Direct Use

直接使用

  1. Check if installed:
    which myfitnesspal-pp-cli
    If not found, offer to install (see Prerequisites at the top of this skill).
  2. Match the user query to the best command from the Unique Capabilities and Command Reference above.
  3. Execute with the
    --agent
    flag:
    bash
    myfitnesspal-pp-cli <command> [subcommand] [args] --agent
  4. If ambiguous, drill into subcommand help:
    myfitnesspal-pp-cli <command> --help
    .
  1. 检查是否已安装:
    which myfitnesspal-pp-cli
    若未找到,提供安装选项(参考顶部前提条件中的安装步骤)。
  2. 将用户查询匹配到上方独特功能和命令参考中最合适的命令。
  3. 添加
    --agent
    参数执行:
    bash
    myfitnesspal-pp-cli <command> [subcommand] [args] --agent
  4. 若存在歧义,查看子命令帮助:
    myfitnesspal-pp-cli <command> --help