|
1 | 1 | ---
|
2 | 2 | title: Call recording
|
3 |
| -subtitle: Record and store calls in Vapi or your own storage |
4 |
| -slug: call-recording |
| 3 | +subtitle: Record and store calls for analysis and training |
| 4 | +slug: assistants/call-recording |
| 5 | +description: Learn how to record calls and store them for quality assurance and analysis |
5 | 6 | ---
|
6 | 7 |
|
7 |
| -The Call Recording feature allows you to capture and store full recordings of phone calls for analysis. By default, Vapi stores a complete recording of every call, providing both mono and stereo audio. The stereo option separates human and assistant audio into two distinct channels, offering a clearer analysis of the conversation. |
8 |
| - |
9 |
| -You can customize this behavior in the assistant's [`assistant.artifactPlan`](/api-reference/assistants/create#request.body.artifactPlan). |
10 |
| - |
11 |
| -## Recording Formats |
12 |
| - |
13 |
| -Vapi supports multiple recording formats to fit your storage and playback needs. |
14 |
| - |
15 |
| -You can specify your preferred format using the [`assistant.artifactPlan.recordingFormat`](/api-reference/assistants/create#request.body.artifactPlan.recordingFormat) property. If not specified, recordings will default to `wav;l16`. |
16 |
| - |
17 |
| -**Supported formats:** |
18 |
| -- `wav;l16` (default) - High quality linear PCM |
19 |
| -- `mp3` - Compressed format for smaller file sizes |
20 |
| -- `flac` - Lossless compression for archival |
| 8 | +## Overview |
| 9 | + |
| 10 | +Vapi provides comprehensive call recording capabilities that allow you to capture, store, and analyze voice conversations for quality assurance, training, and compliance purposes. |
| 11 | + |
| 12 | +**Call recording enables you to:** |
| 13 | +- Monitor conversation quality and assistant performance |
| 14 | +- Train and improve your voice AI models |
| 15 | +- Ensure compliance with regulatory requirements |
| 16 | +- Analyze customer interactions for insights |
| 17 | + |
| 18 | +## Recording Configuration |
| 19 | + |
| 20 | +### Enable Recording |
| 21 | + |
| 22 | +You can enable call recording at the assistant level or per individual call: |
| 23 | + |
| 24 | +<CodeBlocks> |
| 25 | +```json title="Assistant Configuration" |
| 26 | +{ |
| 27 | + "name": "Customer Support Assistant", |
| 28 | + "recordingEnabled": true, |
| 29 | + "model": { |
| 30 | + "provider": "openai", |
| 31 | + "model": "gpt-4" |
| 32 | + }, |
| 33 | + "voice": { |
| 34 | + "provider": "11labs", |
| 35 | + "voiceId": "harry" |
| 36 | + } |
| 37 | +} |
| 38 | +``` |
| 39 | + |
| 40 | +```json title="Per-Call Configuration" |
| 41 | +{ |
| 42 | + "assistant": { |
| 43 | + "name": "Support Agent" |
| 44 | + }, |
| 45 | + "recordingEnabled": true, |
| 46 | + "phoneNumberId": "your-phone-number-id" |
| 47 | +} |
| 48 | +``` |
| 49 | +</CodeBlocks> |
| 50 | + |
| 51 | +### Recording Options |
| 52 | + |
| 53 | +Configure recording behavior with these options: |
| 54 | + |
| 55 | +- **`recordingEnabled`**: Enable or disable recording for this assistant/call |
| 56 | +- **`recordingChannelCount`**: Number of audio channels to record (1 for mono, 2 for stereo) |
| 57 | +- **`recordingFormat`**: Audio format for recordings (mp3, wav, etc.) |
21 | 58 |
|
22 | 59 | ## Storage Options
|
23 | 60 |
|
24 |
| -Vapi supports uploading recordings to your own storage buckets. See [Integrations -> Cloud](/providers/cloud/s3) for more information on available storage options. |
25 |
| - |
26 |
| -**Supported cloud storage providers:** |
27 |
| -- AWS S3 |
28 |
| -- Google Cloud Storage |
29 |
| -- Cloudflare R2 |
30 |
| -- Supabase |
31 |
| - |
32 |
| -## Configuration Options |
| 61 | +### Default Storage |
33 | 62 |
|
34 |
| -### Enable/Disable Recording |
| 63 | +By default, Vapi stores recordings securely in the cloud: |
35 | 64 |
|
36 |
| -You can turn on/off call recording by setting the [`assistant.artifactPlan.recordingEnabled`](/api-reference/assistants/create#request.body.artifactPlan.recordingEnabled) property to `true` or `false`. If not specified, recordings will default to `true`. |
| 65 | +- Recordings are encrypted at rest and in transit |
| 66 | +- Access is controlled through your API credentials |
| 67 | +- Recordings are automatically cleaned up based on your retention policy |
37 | 68 |
|
38 |
| -**HIPAA Compliance:** If [HIPAA](/security-and-privacy/hipaa) mode is enabled, Vapi will only store recordings if you have defined a custom storage bucket. Make sure to set credentials in the Provider Credentials section of your dashboard. |
| 69 | +### Custom Storage |
39 | 70 |
|
40 |
| -### Video Recording |
| 71 | +For advanced use cases, you can configure custom storage: |
41 | 72 |
|
42 |
| -You can turn on/off video recording by setting the [`assistant.artifactPlan.videoRecordingEnabled`](/api-reference/assistants/create#request.body.artifactPlan.videoRecordingEnabled) property to `true` or `false`. If not specified, video recording will default to `false`. |
| 73 | +<CodeBlocks> |
| 74 | +```json title="S3 Storage Configuration" |
| 75 | +{ |
| 76 | + "recordingEnabled": true, |
| 77 | + "recordingPath": "https://your-bucket.s3.amazonaws.com/recordings/", |
| 78 | + "recordingCredentials": { |
| 79 | + "provider": "aws", |
| 80 | + "region": "us-east-1", |
| 81 | + "accessKeyId": "your-access-key", |
| 82 | + "secretAccessKey": "your-secret-key" |
| 83 | + } |
| 84 | +} |
| 85 | +``` |
43 | 86 |
|
44 |
| -## Upload Path |
| 87 | +```json title="Google Cloud Storage" |
| 88 | +{ |
| 89 | + "recordingEnabled": true, |
| 90 | + "recordingPath": "gs://your-bucket/recordings/", |
| 91 | + "recordingCredentials": { |
| 92 | + "provider": "gcp", |
| 93 | + "serviceAccountKey": "your-service-account-json" |
| 94 | + } |
| 95 | +} |
| 96 | +``` |
| 97 | +</CodeBlocks> |
| 98 | + |
| 99 | +## Accessing Recordings |
| 100 | + |
| 101 | +### Via Dashboard |
| 102 | + |
| 103 | +1. Navigate to **Calls** in your Vapi dashboard |
| 104 | +2. Select a specific call from the list |
| 105 | +3. Click on the **Recording** tab to play or download the audio |
| 106 | + |
| 107 | +### Via API |
| 108 | + |
| 109 | +Retrieve recording URLs programmatically: |
| 110 | + |
| 111 | +```typescript |
| 112 | +import { VapiClient } from "@vapi-ai/server-sdk"; |
| 113 | + |
| 114 | +const client = new VapiClient({ token: "your-api-key" }); |
| 115 | + |
| 116 | +// Get call details including recording URL |
| 117 | +const call = await client.calls.get("call-id"); |
| 118 | +console.log("Recording URL:", call.recordingUrl); |
| 119 | +``` |
| 120 | + |
| 121 | +## Privacy and Compliance |
| 122 | + |
| 123 | +### Legal Considerations |
| 124 | + |
| 125 | +**Important**: Call recording laws vary by jurisdiction. Ensure compliance with: |
| 126 | + |
| 127 | +- **Consent requirements** - Inform participants about recording |
| 128 | +- **Data protection** regulations (GDPR, CCPA, etc.) |
| 129 | +- **Industry standards** (PCI DSS, HIPAA, etc.) |
| 130 | + |
| 131 | +### Best Practices |
| 132 | + |
| 133 | +- **Inform callers** about recording at the start of conversations |
| 134 | +- **Secure storage** with encryption and access controls |
| 135 | +- **Retention policies** to automatically delete old recordings |
| 136 | +- **Access logs** to track who accesses recordings |
| 137 | + |
| 138 | +<Warning> |
| 139 | + Always comply with local laws regarding call recording. Some jurisdictions require explicit consent from all parties before recording. |
| 140 | +</Warning> |
| 141 | + |
| 142 | +## Recording Analysis |
| 143 | + |
| 144 | +### Transcription |
| 145 | + |
| 146 | +Recorded calls are automatically transcribed for analysis: |
| 147 | + |
| 148 | +```json |
| 149 | +{ |
| 150 | + "callId": "call-123", |
| 151 | + "transcript": [ |
| 152 | + { |
| 153 | + "role": "assistant", |
| 154 | + "message": "Hello! How can I help you today?", |
| 155 | + "time": 0.5 |
| 156 | + }, |
| 157 | + { |
| 158 | + "role": "user", |
| 159 | + "message": "I need help with my account", |
| 160 | + "time": 3.2 |
| 161 | + } |
| 162 | + ], |
| 163 | + "recordingUrl": "https://api.vapi.ai/recordings/call-123.mp3" |
| 164 | +} |
| 165 | +``` |
| 166 | + |
| 167 | +### Call Analysis |
| 168 | + |
| 169 | +Use recorded data for insights: |
| 170 | + |
| 171 | +- **Conversation flow** analysis |
| 172 | +- **Response quality** evaluation |
| 173 | +- **Customer satisfaction** metrics |
| 174 | +- **Assistant performance** tracking |
| 175 | + |
| 176 | +## FAQ |
| 177 | + |
| 178 | +<AccordionGroup> |
| 179 | + <Accordion title="Are recordings automatically transcribed?"> |
| 180 | + Yes, all recordings are automatically transcribed and available through the API and dashboard. |
| 181 | + </Accordion> |
| 182 | + |
| 183 | + <Accordion title="How long are recordings stored?"> |
| 184 | + Default retention is 30 days. You can configure custom retention policies for your account. |
| 185 | + </Accordion> |
| 186 | + |
| 187 | + <Accordion title="Can I disable recording for specific calls?"> |
| 188 | + Yes, you can enable/disable recording at both the assistant level and per individual call. |
| 189 | + </Accordion> |
| 190 | + |
| 191 | + <Accordion title="Is recording available in all regions?"> |
| 192 | + Call recording is available in all supported Vapi regions with local data residency options. |
| 193 | + </Accordion> |
| 194 | +</AccordionGroup> |
45 | 195 |
|
46 |
| -When uploading recordings to your custom storage bucket, you can specify the upload path using the `assistant.artifactPlan.recordingPath` property. If not specified, recordings will default to the root of the bucket. |
| 196 | +## Next Steps |
47 | 197 |
|
48 |
| -Usage: |
49 |
| -- If you want to upload the recording to a specific path, set this to the path. Example: `/my-assistant-recordings`. |
50 |
| -- If you want to upload the recording to the root of the bucket, set this to `/`. |
| 198 | +- **[Call Analysis](/assistants/call-analysis)** - Analyze recorded conversations for insights |
| 199 | +- **[Privacy Compliance](/security-and-privacy/GDPR)** - Ensure GDPR and privacy compliance |
| 200 | +- **[API Reference](/api-reference/calls/create)** - Explore recording configuration options |
0 commit comments