Voicemail Pro
1. Enable
[proxy]
addons = ["voicemail"]
Database requirements: automatically creates voicemail_box and voicemail_message tables. Supports SQLite / MySQL / PostgreSQL.
2. Mailbox Management
2.1 Create a Mailbox
Console → Voicemail → New Mailbox:
| Field | Description | Example |
|---|---|---|
| Extension | Associated extension number | 1001 |
| PIN | Access password (4-8 digits) | 1234 |
| Notification email address | user@example.com | |
| Greeting | Custom greeting | Upload WAV |
Auto-provisioning via extension lifecycle hooks
When the voicemail addon is enabled, voicemail mailboxes are automatically created when an extension is created through the console or API. Similarly, deleting an extension automatically removes its mailbox and all recorded messages. This is implemented via the on_extension_created / on_extension_deleting addon lifecycle hooks.
You can still create mailboxes manually (e.g., for existing extensions before the addon was enabled), but for new deployments no separate mailbox provisioning step is needed.
2.2 PIN Policy
- 4-8 digit numeric code
- Cannot be all the same digit (e.g. 1111)
- Cannot be sequential (e.g. 1234)
- Stored using Argon2id hash
2.3 Custom Greeting
Mailbox → Greeting → Upload: supports WAV format.
3. Message Flow
Incoming call → No answer / Busy
│
▼
Voicemail App
├── Play greeting (custom or default)
├── Play tone
├── Record message (max duration, silence timeout)
├── Save message
│ ├── Upload to storage backend
│ ├── Write to database
│ └── Send notification
└── Play confirmation tone → Hang up
3.1 Recording Parameters
config/voicemail.toml:
spool_dir = "voicemail_spool"
max_duration = 120 # Max recording 120 seconds
silence_timeout = 5 # Auto-end after 5 seconds of silence
language = "zh"
sounds_dir = "config/sounds/voicemail"
4. Notification Chain
After a message is saved, the system executes notifications in order:
| Method | Description | Configuration |
|---|---|---|
| SMTP notification email | SMTP server configuration | |
| Webhook | HTTP POST to specified URL | URL, Headers |
| SIP MWI | RFC 3842 Message Waiting Indication | Automatic (SIP NOTIFY) |
4.1 Email Configuration
[voicemail.smtp]
host = "smtp.example.com"
port = 587
username = "noreply@example.com"
password = "smtp-password"
from = "noreply@example.com"
use_tls = true
4.2 Webhook Configuration
[voicemail.webhook]
url = "https://api.example.com/voicemail/notify"
headers = { "Authorization" = "Bearer token" }
5. Listening to Messages
5.1 Self-Service Retrieval
Dial *97 → PIN verification → IVR menu:
- Play new messages
- Play saved messages
- Delete messages
- Change PIN
5.2 Web Interface
Console → Voicemail → Mailbox Details:
- Message list (time, caller, duration)
- Online playback
- Download audio
- Mark as read / Delete
6. Storage Backend
Supports multiple storage options:
| Backend | Configuration |
|---|---|
| Local filesystem | storage_type = "local" |
| AWS S3 | storage_type = "s3" |
| Alibaba Cloud OSS | storage_type = "s3" (S3 compatible) |
| Tencent COS | storage_type = "s3" (S3 compatible) |
| MinIO | storage_type = "s3" (S3 compatible) |
| Azure Blob | storage_type = "azure" |
| GCP Storage | storage_type = "gcp" |
[voicemail.storage]
type = "s3"
bucket = "voicemail-recordings"
region = "us-east-1"
endpoint = "https://s3.amazonaws.com"
access_key = "AKIA..."
secret_key = "secret..."
7. Multi-language Prompts
Built-in prompts support 5 languages: en, zh, ja, es, fr
Prompt files are located in the addon’s sounds/ directory. Custom prompts can be uploaded via the console.
8. API
| Operation | Endpoint |
|---|---|
| Mailbox list | GET /console/voicemail |
| Mailbox details | GET /console/voicemail/{ext} |
| Create mailbox | POST /console/voicemail/mailboxes |
| Delete mailbox | POST /console/voicemail/mailboxes/{ext}/delete |
| Reset PIN | POST /console/voicemail/mailboxes/{ext}/reset-pin |
| Upload greeting | POST /console/voicemail/mailboxes/{ext}/greeting |
| Message list | GET /api/voicemail/{ext}/messages |
| Stream playback | GET /api/voicemail/messages/{id}/audio |
| Mark as read | POST /api/voicemail/messages/{id}/read |
| Delete message | POST /api/voicemail/messages/{id}/delete |
| Settings page | GET /console/voicemail/settings |