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:

FieldDescriptionExample
ExtensionAssociated extension number1001
PINAccess password (4-8 digits)1234
EmailNotification email addressuser@example.com
GreetingCustom greetingUpload WAV

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:

MethodDescriptionConfiguration
EmailSMTP notification emailSMTP server configuration
WebhookHTTP POST to specified URLURL, Headers
SIP MWIRFC 3842 Message Waiting IndicationAutomatic (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:

BackendConfiguration
Local filesystemstorage_type = "local"
AWS S3storage_type = "s3"
Alibaba Cloud OSSstorage_type = "s3" (S3 compatible)
Tencent COSstorage_type = "s3" (S3 compatible)
MinIOstorage_type = "s3" (S3 compatible)
Azure Blobstorage_type = "azure"
GCP Storagestorage_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

OperationEndpoint
Mailbox listGET /console/voicemail
Mailbox detailsGET /console/voicemail/{ext}
Create mailboxPOST /console/voicemail/mailboxes
Delete mailboxPOST /console/voicemail/mailboxes/{ext}/delete
Reset PINPOST /console/voicemail/mailboxes/{ext}/reset-pin
Upload greetingPOST /console/voicemail/mailboxes/{ext}/greeting
Message listGET /api/voicemail/{ext}/messages
Stream playbackGET /api/voicemail/messages/{id}/audio
Mark as readPOST /api/voicemail/messages/{id}/read
Delete messagePOST /api/voicemail/messages/{id}/delete
Settings pageGET /console/voicemail/settings