Pipecat's Real-Time Voice Inference - Daily Transport

Daily transport package for use with @pipecat-ai/client-js.
Installation
npm install \
@pipecat-ai/client-js \
@pipecat-ai/daily-transport
Overview
The DailyTransport class provides a WebRTC transport layer using Daily.co's infrastructure. It handles audio/video device management, WebRTC connections, and real-time communication between clients and bots.
Features
- 🎥 Complete camera device management
- 🎤 Microphone input handling
- 🔊 Speaker output control
- 📡 WebRTC connection management
- 🤖 Bot participant tracking
- 📊 Audio level monitoring
- đź’¬ Real-time messaging
Usage
Basic Setup
import { PipecatClient } from "@pipecat-ai/client-js";
import { DailyTransport } from "@pipecat-ai/daily-transport";
const pcClient = new PipecatClient({
transport: new DailyTransport({ dailyFactoryOptions }),
enableCam: false,
enableMic: true,
callbacks: {
},
});
pcClient.connect({
url: 'https://your.daily.co/room'
});
pcClient.connect({
endpoint: 'https://your-server/connect',
});
API Reference
Constructor Options
interface DailyTransportConstructorOptions {
dailyFactoryOptions?: DailyFactoryOptions;
}
States
The transport can be in one of these states:
- "initializing"
- "initialized"
- "connecting"
- "connected"
- "ready"
- "disconnecting"
- "error"
Events
The transport implements the various Pipecat event handlers. Check out the docs or samples for more info.
Error Handling
The transport includes error handling for:
- Connection failures
- Device errors
- Authentication issues
- Message transmission problems
License
BSD-2 Clause