mcpSmartThings
Provides API endpoints for a hotel management frontend and integrates with SmartThings API to control devices based on user preferences and room assignments.
Provides API endpoints for a hotel management frontend and integrates with SmartThings API to control devices based on user preferences and room assignments.
This is a demonstration of the integration between Samsung SmartThings and a hotel booking system, allowing personalized temperature settings based on user preferences.
The demo consists of:
Use an AI chatbot interface to interact with the system
An MCP (Master Control Program) Backend which:
├── app.py # Main Streamlit application
├── mcp/ # MCP backend
│ ├── server.py # FastAPI server
│ ├── smartthings.py # SmartThings API integration
├── utils/ # Utility modules
│ ├── database.py # Local database operations
├── data/ # Data storage (created at runtime)
│ ├── users.json
│ ├── rooms.json
│ ├── bookings.json
├── README.md # This file
Clone this repository:
git clone <repository-url>
cd mcpSmartThings
Install required dependencies:
pip install streamlit fastapi uvicorn pydantic pandas torch transformers
Start the MCP backend server:
cd mcpSmartThings
python -m mcp.server
The MCP server will start on http://localhost:8000
In a new terminal, start the Streamlit frontend:
cd mcpSmartThings
streamlit run app.py
The Streamlit app will open in your browser at http://localhost:8501
Go to the sidebar and click "Load Sample Data" to populate the system with sample users, rooms, and bookings.
Users Tab:
Update existing user temperature preferences
Rooms Tab:
Set room temperatures manually
Bookings Tab:
Process checkouts
Dashboard Tab:
Check SmartThings integration status
Claude Interface Tab:
The SmartThings integration is simulated in this demo. In a real-world implementation, it would connect to the actual SmartThings API to control:
When a guest checks in, their preferred temperature (saved in their profile) is automatically applied to their assigned room through SmartThings.
Once the MCP server is running, you can access the API documentation at: http://localhost:8000/docs
This provides an interactive interface to explore and test all available API endpoints.
data
directory. You can reset the data by clicking "Reset Demo Data" in the sidebar.This demonstration was created by Samsung for illustrating the potential of SmartThings integration with hotel management systems.