A Whatnot-style live shopping web application powered by Agora Web SDK and Agora Conversational AI. Hosts can broadcast video/audio, describe products naturally, and trigger AI-generated product overlays. Audiences can discover and join live channels to watch streams with real-time product information.
- Host Interface: Broadcast video/audio, describe products naturally, control product overlays
- Audience Interface: Browse live channels, join streams, view product overlays
- AI-Powered Product Detection: Automatically parses product descriptions into structured overlays
- Real-time Communication: Powered by Agora Web SDK for low-latency streaming
- Channel Discovery: Browse and search active live shopping channels
- Product History: Pin and manage product information during streams
- Frontend: React 18, Tailwind CSS, Framer Motion
- Real-time: Agora Web SDK (RTC + RTM)
- AI: Agora Conversational AI
- Backend: Netlify Functions (Serverless)
- Deployment: Netlify
- Node.js 18+
- Agora account with App ID and credentials
- Netlify account (for deployment)
# Clone the repository
git clone <repository-url>
cd shopscribe
# Install dependencies
npm install
# Copy environment configuration
cp env.example .envEdit .env with your credentials:
# Agora Configuration
REACT_APP_AGORA_APP_ID=your_agora_app_id_here
AGORA_CERTIFICATE=your_agora_certificate_here
AGORA_CUSTOMER_ID=your_agora_customer_id_here
AGORA_CUSTOMER_SECRET=your_agora_customer_secret_here
# OpenAI Configuration (Optional)
OPENAI_API_KEY=your_openai_key
OPENAI_MODEL=gpt-4o
# TTS Configuration (Optional)
TTS_VENDOR=microsoft
MICROSOFT_TTS_API_KEY=your_microsoft_key
MICROSOFT_TTS_REGION=eastus
# API Configuration
REACT_APP_API_URL=http://localhost:8888# Start development server
npm start
# Or start with Netlify Dev (recommended)
npm run devThe app will be available at http://localhost:3000.
# Build for production
npm run build
# Deploy to Netlify
netlify deploy --prod- Navigate to
/host - Click "Start Stream" to begin broadcasting
- Describe products naturally - AI will automatically detect and create overlays
- Use controls to show/hide overlays, pin products, and move to next product
- Navigate to
/lobbyto browse live channels - Click "Join" on any active channel
- Watch the stream with real-time product overlays
- View live transcript and stream information
The AI automatically detects product information using bracketed tags:
[[product_name: iPhone 15 Pro]]
[[category: Electronics]]
[[brand: Apple]]
[[variant: 256GB Natural Titanium]]
[[features: A17 Pro chip, Pro camera system]]
[[condition: Brand new]]
[[price_estimate: $1,199]]
[[short_copy: Latest iPhone with advanced camera and performance]]
[[theme: tech]]
GET /api/agora/channels- List active channelsPOST /api/agora/agents- Create AI agentPOST /api/agora/agents/chat- Send message to agentPOST /api/agora/agents/interrupt- Interrupt agentPOST /api/agora/agents/stop- Stop agent
REACT_APP_ENABLE_RTM_SYNC- Enable real-time overlay sync (Phase 2)REACT_APP_ENABLE_PRODUCT_HISTORY- Enable product history sidebarREACT_APP_CHANNEL_LIST_REFRESH_MS- Channel list refresh interval
Products support different themes for visual styling:
promo- Red theme for promotional itemsrare- Purple theme for rare/collectible itemstech- Blue theme for technology productsapparel- Green theme for clothing/fashiondefault- Gray theme for general products
src/
├── components/ # React components
│ ├── ProductOverlay.jsx
│ ├── HostControls.jsx
│ ├── VideoStage.jsx
│ ├── AudienceLobby.jsx
│ └── ProductSidebar.jsx
├── pages/ # Page components
│ ├── HostPage.jsx
│ ├── AudiencePage.jsx
│ └── LobbyPage.jsx
├── services/ # Business logic
│ ├── agoraService.js
│ ├── conversationalAIAPI.js
│ └── config.js
├── utils/ # Utilities
│ ├── product-sync.js
│ └── subtitle-clean.js
└── api/ # API clients
└── channelList.js
netlify/functions/ # Serverless functions
├── agora-channels.mjs
├── agora-agents.mjs
└── agora-agents-chat.mjs
- ProductOverlay: Floating overlay displaying product information
- HostControls: Control panel for stream management
- VideoStage: Video container with overlay mounting
- AudienceLobby: Channel discovery interface
- ProductSidebar: Product history management
- Agora SDK not loading: Ensure CDN links are accessible
- Connection failures: Check Agora credentials and network
- Product tags not parsing: Verify AI agent prompt and tag format
- Channel list empty: Check Agora API credentials and permissions
Enable debug logging by setting enableLog: true in the Agora service configuration.
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
MIT License - see LICENSE file for details.
For issues and questions:
- Check the troubleshooting section
- Review Agora documentation
- Open an issue on GitHub