Lemonade Stand MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Lemonade Stand MCP Server start a new game and buy 50 cups, 30 lemons, and 5 pounds of sugar"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🍋 Lemonade Stand MCP Server
A simple, working example of a Model Context Protocol (MCP) server that lets you play the classic Lemonade Stand game through Claude Desktop.
What is MCP?
Model Context Protocol (MCP) is an open standard that enables AI models like Claude to interact with external data sources and tools. This server demonstrates how MCP works by implementing the classic Lemonade Stand game as a set of tools that Claude can use.
Related MCP server: MCP Tools
Features
🌤️ Dynamic weather system affecting sales
💰 Business simulation with supply and demand
📊 Strategic pricing and inventory management
🏁 14-day game cycle with profit tracking
🎮 Fully playable through Claude Desktop
Prerequisites
Node.js (v20.11.1 or higher recommended)
npm (comes with Node.js)
Quick Start
Clone this repository:
git clone https://github.com/yourusername/Lemonade-Stand-MCP-Server.git cd Lemonade-Stand-MCP-ServerInstall dependencies:
npm installFind your Claude Desktop configuration file:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
Configure Claude Desktop:
{ "mcpServers": { "lemonade-stand": { "command": "node", "args": [ "/absolute/path/to/Lemonade-Stand-MCP-Server/server.js" ] } } }Restart Claude Desktop
You should now see a hammer icon in Claude Desktop, indicating the MCP server is connected!
Playing the Game
Once the server is connected, simply start a new chat with Claude and say:
"Play a complete game of Lemonade Stand using the MCP tools available."
Claude will then:
Start a new game
Analyze the weather conditions
Make strategic decisions about supplies and pricing
Report daily results
Continue until Day 14 or your business fails
Game Mechanics
Weather System: Temperature and conditions affect customer traffic
Supply Chain: Buy cups, lemons, sugar, and ice at different prices
Price Strategy: Set your price per cup to balance profit and demand
Inventory Management: Ice melts daily; manage your supplies wisely
Customer Demand: Based on weather, price, and available inventory
Available Tools
The server exposes these MCP tools to Claude:
start_game: Begin a new game sessionget_game_state: Check current status, money, inventory, and weatherbuy_supplies: Purchase cups, lemons, sugar, and iceset_price: Set the price per cup of lemonadesell_lemonade: Open for business and see daily resultsnext_day: Advance to the next day
Configuration Examples
For WSL Users
{
"mcpServers": {
"lemonade-stand": {
"command": "wsl.exe",
"args": [
"/home/username/.nvm/versions/node/v20.11.1/bin/node",
"/home/username/projects/Lemonade-Stand-MCP-Server/server.js"
]
}
}
}Using NPX
{
"mcpServers": {
"lemonade-stand": {
"command": "npx",
"args": [
"/path/to/Lemonade-Stand-MCP-Server/server.js"
]
}
}
}Troubleshooting
No hammer icon in Claude Desktop:
Ensure Claude Desktop is up to date
Check that the configuration file path is correct
Verify Node.js is installed and accessible
Check Claude Desktop logs in:
Windows:
%APPDATA%\Claude\logs\macOS:
~/Library/Logs/Claude/
Server connection error:
Verify the server path in your configuration is absolute
Test the server directly with
node server.jsCheck for any errors in the Claude Desktop logs
WSL-specific issues:
Ensure Node.js is installed in WSL
Use the full path to the Node.js binary
Check WSL is properly installed and running
Development
To modify the server:
Edit
server.jsto change game mechanics or add new toolsTest locally with
node server.jsRestart Claude Desktop to load changes
Project Structure
Lemonade-Stand-MCP-Server/
├── server.js # Main MCP server implementation
├── package.json # Node.js dependencies
└── README.md # This fileHow It Works
This MCP server implements a simple game loop:
The server maintains game state in memory
Each tool represents a game action (buy, sell, etc.)
When Claude calls a tool, the server updates the game state
Results are returned to Claude as JSON
Claude analyzes the results and decides the next action
This demonstrates how MCP can be used to create interactive experiences where AI models can maintain state, make decisions, and interact with complex systems.
Contributing
Feel free to open issues or submit pull requests if you have ideas for improvements or find bugs.
License
MIT
Built as an example of the Model Context Protocol in action.
Available Tools
5 toolsbuy_suppliesC
Purchase supplies for the lemonade stand
Inputs: gameId (required), cups, lemons, sugar, +1 more.
next_dayC
Advance to the next day
Inputs: gameId (required).
sell_lemonadeD
Open for business and see today's results
Inputs: gameId (required).
set_priceC
Set the price per cup of lemonade
Inputs: gameId (required), price (required).
start_gameB
Start a new lemonade stand game
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
Each tool has a clearly distinct purpose with no overlap: buying supplies, advancing time, selling lemonade, setting price, and starting the game. An agent can easily distinguish between these core gameplay actions without confusion.
All tools follow a consistent verb_noun pattern (e.g., buy_supplies, set_price, start_game). The naming is uniform throughout, using snake_case and clear action-oriented verbs that align with the lemonade stand simulation domain.
With 5 tools, this is well-scoped for a lemonade stand game simulation. Each tool serves a specific, essential function (setup, resource management, time progression, sales, pricing), and there are no extraneous or missing tools for this domain.
The toolset covers the core lifecycle of a lemonade stand game: starting, buying supplies, setting price, selling, and advancing days. A minor gap is the lack of tools for viewing game state (e.g., checking inventory or finances), but agents can work around this by tracking results from sell_lemonade.
Maintenance
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Hosted Amazon Seller and Vendor MCP server for Claude, ChatGPT, Cursor, Codex, Gemini, Copilot.
Hosted Amazon Seller Central and Amazon Ads MCP server for Claude, ChatGPT, Cursor, and agents.
Shared memory MCP server for Claude Code, Codex, Gemini CLI and Cursor. Cited, editable.
Related MCP Servers
- AlicenseBqualityDmaintenanceAn educational implementation of a Model Context Protocol server that demonstrates how to build a functional MCP server for integrating with various LLM clients like Claude Desktop.1161MIT
- AlicenseNot gradedqualityCmaintenanceA custom Model Context Protocol server that gives Claude Desktop and other LLMs access to file system operations and command execution capabilities through standardized tool interfaces.23Apache 2.0
- AlicenseAqualityDmaintenanceA Model Context Protocol server that enables interaction with Polymarket prediction markets through Claude Desktop.31MIT
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that enables Claude Desktop to perform file operations like reading, writing, listing directories, and managing files through natural language commands.MIT