Live: staysync.fedkiit.com Β |Β API: ssapi.fedkiit.com Β |Β Telegram Bot: @syncstay_bot
A comprehensive full-stack platform for managing group hotel inventory for MICE events and destination weddings. SyncStay digitizes the entire event lifecycle β from RFP submission to AI-powered hotel recommendations, flight bookings, guest invitations, and payment β replacing offline chaos with a streamlined digital workflow.
- Multi-Role System β Admin, Event Planner, Hotel/Supplier, and Guest roles with granular RBAC permissions
- Event Management β Create and manage events with custom pricing tiers, booking rules, and public/private access control
- Instant Microsite Engine β Auto-generated branded microsites (slug-based URLs) for each approved event with role-based dashboards
- Inventory Management β Lock hotel inventory per event, track real-time room availability via WebSockets
- RFP & Proposal Workflow β Hotels browse events, submit proposals (room pricing, facilities, amenities); planners compare and select
- Booking System β Self-service booking with integrated Razorpay payment gateway
- Real-Time Updates β Socket.IO-powered live inventory changes, booking notifications, and adminβplanner chat
- AI Chatbot Agent β Natural-language event assistant powered by OpenAI Agents SDK with mem0 persistent memory, MCP tool calling, and input/output guardrails
- Semantic Event Search β Events are chunked and embedded (OpenAI
text-embedding-3-large) into Qdrant vector DB for cosine-similarity search - ML Hotel Recommendations β 4-step pipeline: Haversine radius filtering β Qdrant activity vector search β best-match selection β proximity-sorted candidates
- Personalized Event Recommendations β Hybrid scoring (60% vector similarity + 20% popularity + 20% recency) with cold-start fallback to trending events
- MCP Server β FastMCP stdio server exposing
search_eventsandget_event_hotel_proposalstools for the AI agent
- @syncstay_bot β Full Telegram bot for interacting with the SyncStay AI agent
/startβ Welcome & account status check/link email passwordβ Link your SyncStay account to Telegram/unlinkβ Disconnect your account- Any message β forwarded to the AI agent, response sent back in Telegram
- Webhook mode (production) / Polling mode (dev)
- Group Flight Management β Planners configure flights per event, auto-group guests by origin city
- Live Flight Search β Real flight search via TBO/TekTravels API with fare quotes
- Guest Booking β Guests view assigned flights, book, and receive e-tickets
- Bulk Payment β Planner-side upfront payment for private events
- Manual + Bulk Upload β Add guests individually or via Excel/CSV with auto-generated invitation tokens
- Email Invitations β Tokenized invitation links that auto-register/login guests and redirect to the event microsite
- Group Assignment β Auto-creation of inventory groups with flexible guest management
- Analytics Dashboard β Platform-wide stats with interactive Recharts graphs (line, bar, pie) for trends, growth, and revenue
- Event Approvals β Review, approve/reject pending events with comments (real-time socket-updated)
- Audit Logs β Searchable, filterable, exportable (CSV) audit trail of all platform actions
- Feedback / Chat β Real-time bidirectional chat between admins and planners per event
- User Management β Full CRUD across all roles with search, filtering, and password reset
- Razorpay Gateway β Create orders, verify HMAC signatures server-side, record payments with audit logging
- Admin Refunds β Admin-only refund processing
- Granular tracking of event-lifecycle actions (bookings, guest changes, event updates, microsite publish)
- Real-time 30s polling with category filtering and deduplication
- JWT Authentication with refresh tokens
- Role-Based Access Control (RBAC)
- RESTful API architecture
- Real-time WebSocket communication (Socket.IO)
- Responsive UI with Tailwind CSS + Framer Motion animations
- Input validation and sanitization
- Rate limiting, Helmet security headers, CORS
- Comprehensive error handling and logging
| Category | Technology |
|---|---|
| Runtime | Node.js |
| Framework | Express.js |
| Database | MongoDB (Mongoose ODM) |
| Vector DB | Qdrant (5 collections, 3072-dim embeddings) |
| Auth | JWT (jsonwebtoken), bcrypt |
| Real-time | Socket.IO |
| Payments | Razorpay |
| Flights | TBO/TekTravels API |
| Telegram | node-telegram-bot-api |
| Security | Helmet, CORS, Rate Limiting, Express Validator |
| Category | Technology |
|---|---|
| Framework | FastAPI + Uvicorn |
| AI Agent | OpenAI Agents SDK + mem0 |
| Embeddings | OpenAI text-embedding-3-large |
| Vector Search | Qdrant |
| Tool Protocol | MCP (Model Context Protocol) via FastMCP |
| Guardrails | Input/Output tripwire guardrails |
| Geocoding | Nominatim (geopy) |
| Category | Technology |
|---|---|
| Framework | React 18 (JSX) |
| Build Tool | Vite |
| Styling | Tailwind CSS |
| State | Zustand |
| Data Fetching | TanStack Query (React Query) |
| Routing | React Router v6 |
| Forms | React Hook Form |
| Charts | Recharts |
| Icons | Lucide React |
| Notifications | React Hot Toast |
| Animations | Framer Motion |
| Category | Technology |
|---|---|
| Containers | Docker + Docker Compose |
| Frontend Server | Nginx |
| Reverse Proxy | Nginx (production) |
| Vector DB | Qdrant Cloud (or self-hosted via Docker) |
SyncStay/
βββ server/ # Node.js / Express backend
β βββ src/
β β βββ config/ # Environment & DB config
β β βββ controllers/ # Route controllers
β β βββ middlewares/ # Auth, error handling, RBAC
β β βββ models/ # Mongoose models (User, Event, Booking, etc.)
β β βββ routes/ # API route definitions
β β βββ services/ # Business logic (Telegram bot, etc.)
β β βββ sockets/ # Socket.IO event handlers
β β βββ scripts/ # Seed scripts, embedding generation
β β βββ utils/ # Helpers & utilities
β β βββ app.js # App entry point
β βββ Dockerfile
β βββ package.json
β
βββ client/ # React / Vite frontend
β βββ src/
β β βββ components/ # Reusable components (ChatBot, ActivityLog, etc.)
β β βββ layouts/ # Dashboard & Microsite layouts
β β βββ pages/ # All page components
β β βββ services/ # API clients & socket service
β β βββ store/ # Zustand stores
β β βββ styles/ # Global styles
β β βββ utils/ # Helper functions
β βββ Dockerfile
β βββ nginx.conf
β βββ package.json
β
βββ ml-server/ # Python / FastAPI ML backend
β βββ agent/ # AI chatbot agent (OpenAI Agents SDK + mem0)
β βββ event/ # Event embedding & semantic search
β βββ hotel/ # Hotel recommendation engine
β βββ mcp-server/ # MCP tools (event search, hotel proposals)
β βββ index.py # FastAPI app entry point
β βββ Dockerfile
β βββ requirements.txt
β
βββ docker-compose.yml # Main: backend + frontend + ml-server
βββ docker-compose.qdrant.yml # Self-hosted Qdrant vector DB
βββ .env.docker # Production environment variables
- Node.js (v18+)
- Python (3.10+)
- MongoDB (v6+ or Atlas)
- Docker & Docker Compose (for deployment)
git clone https://github.com/Ritam-Vaskar/SyncStay.git
cd SyncStaycd server
npm install
cp .env.example .env # Edit with your credentials
npm run dev # Runs on http://localhost:5001cd client
npm install
npm run dev # Runs on http://localhost:5173cd ml-server
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env # Add OpenAI key, Qdrant credentials
python index.py # Runs on http://localhost:8020cd server
npm run seed # Creates sample users, events, inventory, etc.# Start all services (backend + frontend + ml-server)
docker compose up -d --build
# Optional: self-hosted Qdrant
docker compose -f docker-compose.qdrant.yml up -dBackend (server/.env or .env.docker)
| Variable | Description |
|---|---|
MONGODB_URI |
MongoDB connection string |
JWT_SECRET |
JWT signing secret |
JWT_REFRESH_SECRET |
Refresh token secret |
CLIENT_URL |
Frontend URL(s), comma-separated |
ML_SERVER_URL |
ML server URL (http://ml-server:8020 in Docker) |
RAZORPAY_KEY_ID |
Razorpay key ID |
RAZORPAY_KEY_SECRET |
Razorpay key secret |
TELEGRAM_BOT_TOKEN |
Telegram bot token from BotFather |
SERVER_URL |
Public backend URL (for webhook mode) |
OPENAI_API_KEY |
OpenAI API key |
QDRANT_URL |
Qdrant instance URL |
QDRANT_API_KEY |
Qdrant API key |
TBO_USERNAME / TBO_PASSWORD |
TBO flight API credentials |
EMAIL_USER / EMAIL_PassKey |
Gmail app password for invitations |
ML Server (ml-server/.env)
| Variable | Description |
|---|---|
OPENAI_API_KEY |
OpenAI API key |
BACKEND_URL |
Node backend URL |
QDRANT_URL |
Qdrant instance URL |
QDRANT_API_KEY |
Qdrant API key |
- Create a bot via @BotFather and get the token
- Set
TELEGRAM_BOT_TOKENandSERVER_URLin your env - Deploy the backend, then register the webhook:
curl -F "url=https://your-domain.com/api/telegram/webhook" \ https://api.telegram.org/bot<TOKEN>/setWebhook
- Verify:
curl https://api.telegram.org/bot<TOKEN>/getWebhookInfo
Bot: @syncstay_bot
| Role | Password | Description | |
|---|---|---|---|
| Admin | [email protected] | password123 | Full system access |
| Planner | [email protected] | password123 | Event management |
| Hotel 1 | [email protected] | password123 | Grand Royale Hotel |
| Hotel 2 | [email protected] | password123 | Ocean View Resort |
| Guest 1 | [email protected] | password123 | Regular guest |
| Guest 2 | [email protected] | password123 | Regular guest |
POST /api/auth/registerβ Register new userPOST /api/auth/loginβ Login userGET /api/auth/meβ Get current userPOST /api/auth/logoutβ Logout user
GET /api/eventsβ Get all events (role-filtered)POST /api/eventsβ Create event (Planner)PUT /api/events/:idβ Update eventPUT /api/events/:id/approveβ Approve event (Admin)GET /api/events/:id/recommendationsβ AI hotel recommendationsPOST /api/events/:id/select-recommended-hotelβ Select recommended hotelGET /api/events/microsite/:slugβ Public microsite access
GET /api/inventoryβ Get inventory (role-filtered)POST /api/inventoryβ Create inventoryPUT /api/inventory/:id/lockβ Lock inventory (Planner)PUT /api/inventory/:id/releaseβ Release inventory
GET /api/proposalsβ Get proposalsPOST /api/proposalsβ Submit proposal (Hotel)PUT /api/proposals/:id/reviewβ Review proposal (Planner)GET /api/hotel-proposalsβ Hotel-side proposal management
GET /api/bookingsβ Get bookingsPOST /api/bookingsβ Create bookingPUT /api/bookings/:id/confirmβ Confirm bookingPOST /api/paymentsβ Process Razorpay paymentPOST /api/payments/:id/refundβ Refund (Admin)
GET /api/flightsβ Search flightsPOST /api/flights/bookβ Book flight- Flight management endpoints for planners and guests
POST /api/guest-invitationsβ Send invitations (manual or CSV upload)GET /api/guest-invitations/:tokenβ Accept invitation via token
POST /api/agent/queryβ Query the AI chatbot (proxied to ML server)
POST /api/telegram/webhookβ Telegram webhook receiverGET /api/telegram/statusβ Bot status (Admin)
GET /api/analytics/overviewβ Platform analyticsGET /api/analytics/revenueβ Revenue analyticsGET /api/analytics/audit-logsβ Audit logsGET /api/admin/*β User management, approvals, feedback
GET /api/activityβ Event activity logsGET /api/recommendationsβ Personalized event recommendations
| Direction | Event | Description |
|---|---|---|
| Client β Server | join-event |
Join event room for live updates |
| Client β Server | leave-event |
Leave event room |
| Client β Server | join-user |
Join user room for notifications |
| Server β Client | inventory-update |
Real-time inventory changes |
| Server β Client | booking-notification |
New booking alerts |
| Server β Client | notification |
User-specific notifications |
| Bidirectional | chat-message |
Admin β Planner feedback chat |
| Model | Description |
|---|---|
| User | Auth, profile, role, telegramId, vector embeddings |
| Event | Event details, config, slug, pricing tiers |
| Inventory | Room inventory per event with lock/release |
| Proposal | RFP proposals from hotels |
| Booking | Guest bookings with status tracking |
| Payment | Razorpay payment records |
| UserActivity | Per-user activity for recommendation engine |
| AuditLog | System-wide audit trail |
- JWT authentication with refresh tokens
- Password hashing (bcrypt, 12 rounds)
- Role-based access control on every route
- Rate limiting (300 req / 15 min per IP)
- Helmet security headers
- CORS with allowlisted origins
- Input validation & sanitization
- XSS & injection protection
The platform is deployed as 3 Docker containers behind Nginx:
Internet β Nginx (reverse proxy)
βββ staysync.fedkiit.com β frontend container (:3030)
βββ ssapi.fedkiit.com β backend container (:5001)
βββ (internal) β ml-server container (:8020)
# On production server
git pull
docker compose up -d --build- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
MIT License β feel free to use this project for learning or commercial purposes.
Built with β€οΈ using MERN Stack + FastAPI + OpenAI + Qdrant
Last Updated: March 2026