Skip to main content
Glama
chrischall

myhotlunchbox-mcp

by chrischall

myhotlunchbox-mcp

面向 My Hot Lunchbox 的 MCP 服务器——读取学校午餐日历、管理学生、下单和改单,并在家长账户上跟踪配送和付款。

由 AI(Claude Code)开发和维护。请自行斟酌使用。

安装

npx myhotlunchbox-mcp

或作为 Claude Code 插件安装:

/plugin marketplace add chrischall/myhotlunchbox-mcp
/plugin install myhotlunchbox-mcp

Related MCP server: Corben MCP Server

配置

MYHOTLUNCHBOX_USERNAME=you@example.com
MYHOTLUNCHBOX_PASSWORD=…

这就是全部配置。服务器会对 ordernow.myhotlunchbox.com 执行真实的服务器端登录(OAuth2 密码授权),并使用收到的刷新令牌续期会话——无需浏览器扩展、无需已登录的标签页、无需捕获 cookie。不会向磁盘写入任何内容。

如果应用源地址发生变化,MYHOTLUNCHBOX_BASE_URL 可覆盖应用源。

服务器在无凭据的情况下启动,因此宿主机安装时的 tools/list 探测仍然可用;配置错误会在第一次工具调用时显现。

工具

34 个工具,全部以 mhlb_ 为前缀。全部 20 个读取工具已针对真实家长账户在线验证(node scripts/verify-reads.mjs);14 个写入工具未经验证——见下文。

账户mhlb_whoamimhlb_session_reset

学生mhlb_list_studentsmhlb_get_student_formmhlb_new_student_formmhlb_create_studentmhlb_update_studentmhlb_delete_student

日历mhlb_get_calendarmhlb_get_day

下单mhlb_get_cartmhlb_get_cart_tabsmhlb_get_menumhlb_get_order_formmhlb_get_ordermhlb_create_ordermhlb_update_ordermhlb_delete_order

账单mhlb_list_transactionsmhlb_get_transactionmhlb_list_subscriptionsmhlb_get_subscription_settingsmhlb_set_subscription_enabledmhlb_unsubscribe_ordermhlb_list_gift_cardsmhlb_apply_gift_cardmhlb_get_couponmhlb_apply_couponmhlb_remove_coupon

结算mhlb_init_checkoutmhlb_checkout

报表mhlb_print_calendarmhlb_print_ordersmhlb_print_transaction。这些工具返回真实的 PDF;每个工具都会写入文件并返回文件路径,或使用 inline: true 以内联字节形式返回。设置 MYHOTLUNCHBOX_OUTPUT_DIR 可选择文件保存位置(默认为工作目录);现有文件绝不会被覆盖。

写入操作需确认门控

每个变更工具都接受 confirm 参数。没有 confirm: true 时,它不会发起任何网络调用,而是返回一个干运行预览,精确展示它将发送的内容。

mhlb_checkout 会从真实支付方式扣款。服务器根据 orderIds 计算扣款金额,因此客户端无法绑定金额——请求中没有可供核对的总金额。因此 expectedTotal归因而非防护:你声明预期金额,该金额会被记录在干运行和结果中,以便意外扣款可追溯到发起该调用的请求。该工具明确拒绝的唯一情况是:在没有 orderIds 的情况下支付非零金额。

写入操作:已捕获请求结构,但未验证服务端是否接受

npm run capture:writes 会针对本地代理运行每个变更工具,该代理将读取请求转发到真实服务,但自行应答写入请求,因此请求体是基于真实的服务器模型构建的,上游不会发生任何操作。它还证明了全部 13 个工具在没有 confirm: true 的情况下都会拒绝发送任何内容。

由此确定并修正的内容:mhlb_delete_ordermhlb_unsubscribe_order 接受 {orderId, eventDate, studentId, isRepeated, isSubscribed}——而非订单模型——结算接受 {orderIds, checkoutType, couponCode, giftCardCode, schoolDonations}

仍未验证的是服务器是否接受这些请求体。 结构不等于被接受;只有真实的写入才能证明这一点,而目前尚未进行过任何真实写入。确认前请检查干运行预览,确认后请再次查看——200 并不能证明写入已持久化。

mhlb_checkout 有两个特定限制:

  • 它只能使用账户上已保存的卡进行支付。使用新卡支付需要由浏览器中的 Stripe.js 铸造 Stripe 令牌,任何服务端客户端都无法生成。

  • 它会生成一个幂等键并返回。如果结算以不明确的方式失败,请使用相同的 idempotencyKey 重试,而不是发起新的调用——这正是防止重试变成第二次扣款的机制。

下单是读-改-写模式

没有"添加商品 X"这样的调用。获取模型、编辑、整体发回:

  1. mhlb_get_menu — 某学生在某日期可订购的内容

  2. mhlb_get_order_form — 需要填写的订单模型

  3. mhlb_create_order — 发回(带 confirm: true

  4. mhlb_init_checkoutmhlb_checkout — 计价,然后支付

请求体中省略的字段会被清空,而非保留。

Shell 技能

skills/myhotlunchbox 使用 curl 从 shell 覆盖同一账户——无需 MCP 进程。适用于脚本,或未安装此服务器的机器。

备注

  • 编译后的客户端中 /deliveryInfo/*/calendar/viewMatchedVendors 看起来面向家长,但对家长账户返回 403——它们属于学校/供应商仪表盘。没有工具封装它们。

  • 仅接入了家长角色。同一 API 也服务于学校管理员和供应商角色;这些端点返回 403,客户端将其报告为角色不匹配,而非会话故障。

  • docs/MYHOTLUNCHBOX-API.md 记录了 API 的映射方式以及已验证的确切内容。docs/api-surface.txt 是完整的 359 个端点提取结果。

许可证

MIT

Install Server
A
license - permissive license
A
quality
A
maintenance

Maintenance

Maintainers
Response time
0dRelease cycle
3Releases (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
    B
    maintenance
    MCP server for Microsoft Outlook via Graph API. 20 consolidated tools for email, calendar, contacts, folders, rules, categories, and settings with safety controls (dry-run preview, rate limiting, recipient allowlists) and MCP annotations on every tool.
    22
    838
    33
    MIT
  • F
    license
    Not graded
    quality
    C
    maintenance
    Provides AI agents with 220+ tools for building websites, sending email, managing contacts, invoicing, databases, automation, and more through a single secure connection. Features hardware-bound authentication and works with Claude Desktop, Claude Code, Cursor, and other MCP-compatible clients.
  • F
    license
    A
    quality
    C
    maintenance
    Enables interacting with the Lunch Money personal finance API through MCP tools for retrieving user info, transactions, and performing calculations, with minimal response sizes.
    6
  • A
    license
    Not graded
    quality
    C
    maintenance
    Provides programmatic access to Grubhub's food delivery platform, enabling restaurant search, menu browsing, cart management, order placement, and delivery tracking through MCP tools.
    MIT

View all related MCP servers

Related MCP Connectors

  • Browser MCP for logged-in tasks. Uses your Chrome — credentials stay local. Zero-token replay.

  • Shopify MCP Pack — wraps the Shopify Admin REST API (2024-01)

  • Access Kernel's cloud-based browsers and app actions via MCP (remote HTTP + OAuth).

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/chrischall/myhotlunchbox-mcp'

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