An AI voice appointment assistant using OpenAI's Realtime API for B2B Accelerator consultations.
- Voice-based appointment booking
- Real-time conversation with AI assistant
- Client information integration
- Automatic appointment capture and external API posting
- Interruption handling for natural conversations
- Create virtual environment:
python3.10 -m venv venv
source venv/bin/activate # On macOS/Linux- Install dependencies:
pip install -r requirements.txt- Create
.envfile:
cp .env.example .envThen add your OpenAI API key and external API URL to the .env file.
- Run the server:
python main.pyPOST to /clients with client information:
curl -X POST http://localhost:8000/clients \
-H "Content-Type: application/json" \
-d '{"info": "Tech startup looking to scale sales operations"}'This returns a clientId.
Open your browser to http://localhost:8000/{clientId} and click "Start Conversation" to begin booking an appointment.
The AI assistant will:
- Greet the client
- Answer questions about B2B Accelerator programs
- Help schedule a consultation appointment
- Automatically POST appointment data to your configured external API
POST /clients- Create a new clientGET /{client_id}- Access appointment assistant for a clientWS /ws/voice/{client_id}- WebSocket for voice communication