Willys MCP Server
An MCP server for Sweden's largest grocery chain Willys. Enables controlling your shopping cart, browsing orders, searching products, and getting AI-powered recommendations from any MCP client.
README
Willys MCP Server
An MCP (Model Context Protocol) server for Willys — Sweden's largest grocery chain. Control your shopping cart, browse orders, search products, and get AI-powered recommendations directly from Claude Code or any MCP client.
<!-- TODO: Add demo GIF
-->
Features
- 19 MCP Tools — Cart, orders, search, delivery slots, promotions, and more
- Smart Matching — AI-powered product recommendations using your purchase history (OpenAI embeddings + sqlite-vec)
- Web Interface — Next.js app for browsing orders and testing features
- Persistent Sessions — SQLite-backed with 24h expiration
- Order Caching — Reduces API calls by 80-90%
Quick Start
git clone https://github.com/yourusername/willys-checklist.git
cd willys-checklist
npm install
Create .credentials in the project root:
your-email@example.com
your-password
Claude Code Integration
Add to ~/.claude.json:
{
"mcpServers": {
"willys-checklist": {
"type": "stdio",
"command": "npx",
"args": ["tsx", "/absolute/path/to/willys-checklist/mcp-server.ts"]
}
}
}
Restart Claude Code. Then just ask:
"Log in to Willys and show me my cart" "Search for havremjölk" "What did I order last week?" "Add Oatly Barista to my cart"
Web Interface
npm run dev
<!-- TODO: Add web interface screenshot
-->
MCP Tools
Auth
| Tool | Description |
|---|---|
mcp__willys_login |
Login, returns session ID |
mcp__willys_logout |
Clear session |
mcp__willys_check_auth |
Check auth status |
Cart
| Tool | Description |
|---|---|
mcp__willys_get_cart |
Get cart contents |
mcp__willys_add_to_cart |
Add product (e.g., 101175556_ST) |
mcp__willys_remove_from_cart |
Remove product |
mcp__willys_checkout |
Start checkout |
Orders
| Tool | Description |
|---|---|
mcp__willys_get_orders |
Order history |
mcp__willys_get_order_details |
Full order with items |
Search
| Tool | Description |
|---|---|
mcp__willys_search |
Product search |
mcp__willys_search_suggestions |
Autocomplete |
mcp__willys_get_product_detail |
Product info |
mcp__willys_get_common_products |
Your frequent items |
mcp__willys_get_smart_product_matches |
AI-powered matching |
Delivery
| Tool | Description |
|---|---|
mcp__willys_get_delivery_slots |
Delivery times |
mcp__willys_get_pickup_slots |
Pickup times |
mcp__willys_select_slot |
Book slot |
Other
| Tool | Description |
|---|---|
mcp__willys_get_offers |
Current promotions |
mcp__willys_get_customer_info |
Profile & bonus |
Smart Product Matching
Enable AI-powered recommendations by setting:
export OPENAI_API_KEY=sk-...
The system uses your purchase history + semantic search to find products you're likely to want.
Project Structure
├── mcp-server.ts # Stdio MCP server
├── app/ # Next.js web UI
├── lib/
│ ├── database.ts # SQLite layer
│ ├── mcp-auth.ts # Puppeteer login
│ ├── mcp-orders.ts # API operations
│ ├── mcp-session-store.ts
│ ├── embeddings.ts # OpenAI embeddings
│ └── types.ts
├── actions/ # Server actions
└── components/ # React components
Development
npm run dev # Dev server (port 3000)
npm run lint # Biome check
npm run format # Biome format
Notes
- Product codes:
101175556_STformat - Full Swedish character support (ö, ä, å)
- Sessions expire after 24 hours
- CSRF handling built-in
Troubleshooting
MCP not connecting?
Check the path in ~/.claude.json is absolute. Verify npx tsx works.
Login fails?
Check .credentials file. Puppeteer may need deps on Linux.
Smart matching empty?
Set OPENAI_API_KEY. First run indexes history.
License
MIT License
Copyright (c) 2025
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Disclaimer: Not affiliated with Willys or Axfood. Use responsibly.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。