AI Skill Hub 推荐使用:MacroFactor营养追踪 是一款优质的MCP工具。AI 综合评分 7.8 分,在同类工具中表现稳健。如果你正在寻找可靠的MCP工具解决方案,这是一个值得深入了解的选择。
MacroFactor营养追踪 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
MacroFactor营养追踪 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
# 方式一:通过 Claude Code CLI 一键安装
claude skill install https://github.com/sjawhar/macrofactor
# 方式二:手动配置 claude_desktop_config.json
{
"mcpServers": {
"macrofactor----": {
"command": "npx",
"args": ["-y", "macrofactor"]
}
}
}
# 配置文件位置
# macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
# Windows: %APPDATA%/Claude/claude_desktop_config.json
# 安装后在 Claude 对话中直接使用 # 示例: 用户: 请帮我用 MacroFactor营养追踪 执行以下任务... Claude: [自动调用 MacroFactor营养追踪 MCP 工具处理请求] # 查看可用工具列表 # 在 Claude 中输入:"列出所有可用的 MCP 工具"
// claude_desktop_config.json 配置示例
{
"mcpServers": {
"macrofactor____": {
"command": "npx",
"args": ["-y", "macrofactor"],
"env": {
// "API_KEY": "your-api-key-here"
}
}
}
}
// 保存后重启 Claude Desktop 生效
pnpm install
npm install -g @sjawhar/macrofactor-mcp
```bash
```bash
import { MacroFactorClient } from './src/lib/api/index';
import { resolveExercise } from './src/lib/api/exercises';
const client = await MacroFactorClient.login(email, password);
// Read workouts
const workouts = await client.getWorkoutHistory();
const detail = await client.getWorkout(workouts[0].id);
// Resolve hex exercise IDs to names
const info = resolveExercise(detail.blocks[0].exercises[0].exerciseId);
console.log(info.name, info.primaryMuscles);
// Read today's food log
const food = await client.getFoodLog('2026-03-19');
// Search and log food
const results = await client.searchFoods('broccoli raw');
const serving = results[0].servings.find((s) => s.description === 'baby leaf');
await client.logSearchedFood(new Date(), results[0], serving, 150, true);
For remote clients that support HTTP-based MCP servers:
MACROFACTOR_USERNAME=you@email.com \
MACROFACTOR_PASSWORD=yourpass \
MCP_AUTH_TOKEN=$(openssl rand -hex 32) \
node dist/mcp/http.js
Add to your Claude Code config file (~/.claude/config.json or project .claude/config.json):
{
"mcpServers": {
"macrofactor": {
"command": "npx",
"args": ["@sjawhar/macrofactor-mcp"],
"env": {
"MACROFACTOR_USERNAME": "you@email.com",
"MACROFACTOR_PASSWORD": "yourpass"
}
}
}
}
Other agents (Cursor, Windsurf) use the same pattern with their own config files.
A TypeScript client and CLI for interacting with MacroFactor programmatically — the nutrition and workout tracker by Stronger By Science.
This is not a replacement for MacroFactor. You need an active MacroFactor subscription to use this. We love MacroFactor and the team behind it. This project exists because sometimes you want to interact with your own data without opening an app — batch-log meals from a script, update workout weights from a spreadsheet, or build your own integrations on top of an already great product.
| Command | Description |
|---|---|
workouts | List recent workouts with exercise/set counts |
workout <uuid> | Full detail for a specific workout |
exercises search "query" | Search the bundled exercise database |
exercise <hex-id> | Resolve a hex ID to exercise name + muscles |
gyms | List gym profiles |
food-log [YYYY-MM-DD] | Show food log for a date (default: today) |
search-food "query" | Search the food database without logging |
log-food '{JSON}' | Search and log a food entry (JSON input) |
log-workout '{JSON}' | Create a workout with exercises (JSON input) |
log-exercise '{JSON}' | Add exercises to an existing workout (JSON input) |
log-weight '{JSON}' | Log a scale entry (JSON input) |
delete-food '{JSON}' | Delete a food entry (JSON input) |
update-food '{JSON}' | Update a food entry quantity (JSON input) |
profile | Show user profile and preferences |
优秀的MCP实践项目,展现多端集成能力。营养健身垂直应用前景好,但需关注用户基数和长期维护承诺。
该工具未明确声明开源协议,商业使用前请联系原作者确认授权范围,避免侵权风险。
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
总体来看,MacroFactor营养追踪 是一款质量良好的MCP工具,在同类工具中具备一定竞争力。AI Skill Hub 将持续追踪其更新动态,建议收藏备用,结合自身场景选择合适时机引入使用。
| 原始名称 | macrofactor |
| 原始描述 | 开源MCP工具:CLI, MCP server, and SvelteKit web app for the MacroFactor nutrition and workout。⭐22 · TypeScript |
| Topics | 营养追踪健身管理MCP服务开源工具 |
| GitHub | https://github.com/sjawhar/macrofactor |
| 语言 | TypeScript |
收录时间:2026-05-22 · 更新时间:2026-05-23 · License:未公布 · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端