System Architecture
Rendez-vous.ai is designed as a distributed, microservices-based architecture to ensure scalability, modularity, and separation of concerns between the frontend interfaces, the AI orchestration backend, and the telephony infrastructure.
The system is composed of four primary active services deployed via Kubernetes, communicating with each other and external providers.
High-Level Diagram
Core Components
1. Dashboard & CMS (rdv.ai-dashboard)
Built with Next.js (App Router) and Payload CMS. Unlike traditional architectures where the backend holds the database schema, in Rendez-vous.ai, Payload CMS acts as the single source of truth. It manages the PostgreSQL database, exposing a GraphQL API. It handles:
- User authentication and tenant management.
- Configuration of AI Agents (prompts, assigned tools, business hours).
- Logging of all conversations (Voice and Web).
- Appointment and billing management.
2. Core API (rdv.ai-API)
Built with Node.js and Express. This is the “brain” of the ecosystem. It does not have its own database; instead, it queries the Dashboard’s Payload CMS using a generated GenQL client.
- Orchestration: Routes requests to the appropriate LLM (Google Gemini, OpenAI).
- Telephony Controller: Receives webhooks from FreeSWITCH, manages the call state, and handles audio stream buffers.
- Web Agent Controller: Manages state for the text-based website widgets.
- Tool Execution: When the LLM decides to call a function (e.g.,
suggestEventSlots,BookingRequestTool,searchTournaments), this API executes the logic against external services and feeds the result back to the LLM.
3. Telephony Engine (rdv.ai-FreeSWITCH)
A heavily customized FreeSWITCH deployment.
- Acts as a SIP Server interfacing with SIP Trunk providers (Twilio, VoIP.ms).
- Uses dialplans and SIP profiles to route incoming phone numbers to specific AI agents.
- Bridges the raw RTP audio streams from the telephone network into formats consumable by the Core API and the LLM audio models.
4. Web Widget (rdv.ai-widget)
A lightweight React and Vite application compiled into an embeddable IIFE script (rdv-ai-widget.iife.js).
- Injected by clients into their own websites.
- Communicates directly with the Core API to provide a seamless text-based chat experience.
Infrastructure (k8s)
The entire stack is containerized using Docker and orchestrated via Kubernetes.
- StatefulSets are used for persistent data (PostgreSQL, S3/MinIO for recordings).
- Deployments manage the stateless API, Dashboard, and FreeSWITCH instances.
- Ingress controllers manage routing traffic to the correct service based on subdomains (e.g.,
api.rendez-vous.ai,app.rendez-vous.ai).