# π€ MCP Website Chatbot - Quick Start Guide
Welcome! Your production-grade website chatbot application is ready. Here's how to get started:
## π What's Included
Your app has been built with these files:
```
βββ server.js β Express backend with chat API
βββ public/index.html β Beautiful chat UI
βββ mcp-client.js β MCP tool integration module
βββ system_prompt.txt β AI system prompt
βββ package.json β Dependencies
βββ .env.example β Environment template
βββ README.md β Full documentation
βββ Dockerfile β Docker containerization
βββ docker-compose.yml β Docker Compose setup
βββ setup.sh β Auto-setup script
```
## π Quick Start (3 Steps)
### Step 1: Install Dependencies
```bash
cd /Users/srinivasanramanujam/Documents/AgenticAI/MCPserverForwebsite
npm install
```
### Step 2: Start the Server
```bash
npm run dev
```
You should see:
```
π€ MCP Chatbot Server running on http://localhost:3000
π± Frontend: http://localhost:3000
π¬ Chat API: POST http://localhost:3000/api/chat
```
### Step 3: Open in Browser
Visit: **http://localhost:3000**
## π¬ Try It Out
Test the chatbot with these queries:
- "Hello!" β Gets a welcome message
- "What is srinivasanramanujam.sbs?" β Learns about the site
- "What's the latest news?" β Triggers live data fetching (with MCP)
- "Can you check the current status?" β Demonstrates real-time verification
## π§ Configuration
### Update API Keys (Production)
Edit `.env`:
```bash
cp .env.example .env
# Add your OpenAI/Claude API key
OPENAI_API_KEY=sk-...
```
### Customize System Prompt
Edit `system_prompt.txt` to change chatbot behavior, voice, or knowledge.
### Update Website Info
In `server.js`, modify:
```javascript
WEBSITE_NAME: 'srinivasanramanujam.sbs'
WEBSITE_URL: 'https://srinivasanramanujam.sbs'
```
## π Deployment Options
### **Vercel (Easiest β Recommended)**
```bash
npm install -g vercel
vercel
```
Follow the prompts to deploy instantly.
### **Docker (Any Cloud)**
```bash
# Build image
docker build -t mcp-chatbot .
# Run container
docker run -p 3000:3000 mcp-chatbot
# Or use Docker Compose
docker-compose up
```
### **Heroku**
```bash
heroku create your-app-name
git push heroku main
```
## π API Endpoints
### Send a Chat Message
```bash
curl -X POST http://localhost:3000/api/chat \
-H "Content-Type: application/json" \
-d '{"message":"Hello!"}'
```
### Check Server Health
```bash
curl http://localhost:3000/api/health
```
### Get System Prompt
```bash
curl http://localhost:3000/api/system-prompt
```
## π Key Features
β
**Live Data Integration** β MCP tools for real-time retrieval
β
**Hallucination Prevention** β Strict guardrails against misinformation
β
**Beautiful UI** β Modern, responsive chat interface
β
**Production-Ready** β Error handling, health checks, logging
β
**Easy to Customize** β Change prompts, add APIs, modify UI
β
**Containerized** β Dockerfile for easy deployment
## π Security Highlights
- β
System prompt not exposed to users
- β
Input validation and sanitization
- β
No secrets in version control (.gitignore setup)
- β
Rate limiting ready (add middleware as needed)
- β
Error messages don't leak internal details
## π― Next Steps
1. **Test locally** β Run `npm run dev` and chat
2. **Integrate real API** β Add OpenAI/Claude API key to `.env`
3. **Connect MCP server** β Point to your actual MCP server in `server.js`
4. **Customize appearance** β Edit CSS in `public/index.html`
5. **Deploy** β Use Vercel, Docker, or your preferred host
6. **Monitor** β Check health endpoint and error logs regularly
## π Documentation
- **Full README**: See `README.md` for detailed setup & API docs
- **System Prompt**: See `system_prompt.txt` for chatbot behavior rules
- **MCP Client**: See `mcp-client.js` for tool integration details
## π Troubleshooting
**Port 3000 already in use?**
```bash
npm run dev -- --port 3001
```
**Dependencies not installing?**
```bash
rm -rf node_modules package-lock.json
npm install
```
**Module errors?**
```bash
npm install
npm run dev
```
## π‘ Pro Tips
1. **Add rate limiting** β Install `express-rate-limit` package
2. **Add CORS** β Use `cors` package for cross-origin requests
3. **Add logging** β Use `winston` for structured logging
4. **Add database** β Store conversations with MongoDB/PostgreSQL
5. **Add authentication** β Protect sensitive endpoints
## π Support & Questions
- Check `README.md` for comprehensive documentation
- Review system prompt in `system_prompt.txt`
- Examine `server.js` for implementation details
---
**Happy chatting! π**
Your chatbot is ready to serve srinivasanramanujam.sbs with intelligence and accuracy.