Use the official McDonald's China MCP toolchain, not scraped web APIs.
Core workflow
- 1. Identify the delivery address.
- Call
delivery-query-addresses first. - Pick the matching address record and carry forward
addressId, storeCode, and beCode from the same record. - Call
query-meals for that store. - If needed, call
query-meal-detail for a chosen meal code. - Call
calculate-price before ordering. - Show the user the real payable amount and wait for confirmation.
- Call
create-order only after confirmation. - Return the
payH5Url to the user. - After the user says payment is complete, call
query-order.
Important constraints
- - Use server URL
https://mcp.mcd.cn. - Send
Authorization: Bearer <TOKEN>. - MCP protocol version must be
2025-06-18 or earlier. - Prefer low request volume; the docs say 600 requests/minute/token.
- Do not invent
storeCode, beCode, or addressId. - For delivery ordering, always use values returned by
delivery-query-addresses or delivery-create-address. - Always price-check with
calculate-price before create-order. - INLINECODE20 docs note that replacing default combo choices is not yet supported in current version.
Tool map
Delivery ordering
- -
delivery-query-addresses: list saved deliverable addresses - INLINECODE22 : add a new delivery address
- INLINECODE23 : coupons usable for the chosen store
- INLINECODE24 : menu for the chosen store
- INLINECODE25 : inspect a meal / combo
- INLINECODE26 : final price check
- INLINECODE27 : create payable delivery order
- INLINECODE28 : query order status after creation/payment
Other useful tools
- -
available-coupons: claimable coupons - INLINECODE30 : one-click claim current coupons
- INLINECODE31 : coupon wallet
- INLINECODE32 : nutrition list
- INLINECODE33 : points account
- INLINECODE34 ,
mall-product-detail, mall-create-order: points mall - INLINECODE37 : marketing calendar
- INLINECODE38 : server time
Recommended user-facing flow
When the user says “帮我点麦当劳” or similar:
- - Confirm budget / preferred item if missing.
- Resolve the delivery address from saved addresses first.
- Find candidate items from
query-meals. - Use
calculate-price for one or a few concrete combinations. - Present the cheapest / best-fit options with real payable totals.
- Only place the order after explicit confirmation.
- After order creation, send the payment link.
- After payment, query
query-order instead of assuming success.
Files in this skill
- - Read
references/api.md for the compact API cheat sheet and tested field names. - Use
scripts/mcd_rpc.py for direct RPC calls to the remote MCP server when you need deterministic testing or CLI usage. - INLINECODE44 contains a Python wrapper around the same remote MCP calls.
- INLINECODE45 contains lightweight text parsing for order intent.
- INLINECODE46 contains higher-level helper functions.
Packaging notes
Keep the skill folder lean.
Do not add extra docs beyond what is needed for reuse.
Remove transient files like __pycache__ before packaging.
技能名称: mcdonalds-mcp-order-lite
详细描述:
使用官方麦当劳中国MCP工具链,而非抓取的网页API。
核心工作流程
- 1. 确定配送地址。
- 首先调用 delivery-query-addresses。
- 选择匹配的地址记录,并从同一记录中提取 addressId、storeCode 和 beCode。
- 针对该门店调用 query-meals。
- 如有需要,针对所选餐品代码调用 query-meal-detail。
- 下单前调用 calculate-price。
- 向用户展示实际应付金额,并等待确认。
- 仅在确认后调用 create-order。
- 将 payH5Url 返回给用户。
- 用户告知支付完成后,调用 query-order。
重要约束
- - 使用服务器URL https://mcp.mcd.cn。
- 发送 Authorization: Bearer 。
- MCP协议版本必须为 2025-06-18 或更早版本。
- 优先减少请求量;文档说明为600次请求/分钟/令牌。
- 不要自行编造 storeCode、beCode 或 addressId。
- 对于配送订单,始终使用 delivery-query-addresses 或 delivery-create-address 返回的值。
- 在 create-order 之前,始终使用 calculate-price 进行价格检查。
- query-meal-detail 文档指出,当前版本尚不支持替换默认套餐选项。
工具映射
配送下单
- - delivery-query-addresses:列出已保存的可配送地址
- delivery-create-address:添加新配送地址
- query-store-coupons:所选门店可用的优惠券
- query-meals:所选门店的菜单
- query-meal-detail:查看餐品/套餐详情
- calculate-price:最终价格检查
- create-order:创建可支付的配送订单
- query-order:查询创建/支付后的订单状态
其他实用工具
- - available-coupons:可领取的优惠券
- auto-bind-coupons:一键领取当前优惠券
- query-my-coupons:优惠券钱包
- list-nutrition-foods:营养列表
- query-my-account:积分账户
- mall-points-products、mall-product-detail、mall-create-order:积分商城
- campaign-calendar:营销日历
- now-time-info:服务器时间
推荐面向用户的流程
当用户说“帮我点麦当劳”或类似内容时:
- - 如果缺少预算或偏好商品,先进行确认。
- 首先从已保存地址中确定配送地址。
- 通过 query-meals 查找候选商品。
- 使用 calculate-price 针对一个或几个具体组合进行价格计算。
- 展示最便宜/最合适的选择及实际应付总额。
- 仅在明确确认后下单。
- 订单创建后,发送支付链接。
- 支付完成后,查询 query-order 而非假定成功。
本技能中的文件
- - 阅读 references/api.md 获取简洁的API速查表和经过测试的字段名称。
- 当需要进行确定性测试或CLI使用时,使用 scripts/mcdrpc.py 对远程MCP服务器进行直接RPC调用。
- client.py 包含对相同远程MCP调用的Python封装。
- nlpprocessor.py 包含用于订单意图的轻量级文本解析。
- tools.py 包含更高级的辅助函数。
打包说明
保持技能文件夹精简。
不要添加超出复用所需的额外文档。
打包前移除临时文件,如 pycache。