Notification
Notification settings (enable/disable, channels, recipients) can be configured directly from the Configuration page in the web UI.
This page covers additional setup guides for each channel.
Email
Databasement uses Laravel's mail system. Configure your mail driver with these environment variables:
MAIL_MAILER=smtp
MAIL_HOST=smtp.example.com
MAIL_PORT=587
MAIL_USERNAME=your-username
MAIL_PASSWORD=your-password
MAIL_ENCRYPTION=tls
MAIL_FROM_ADDRESS=databasement@example.com
MAIL_FROM_NAME="Databasement"
Slack
To receive failure notifications in Slack, you need to create an Incoming Webhook:
- Go to Slack API Apps
- Click Create New App > From scratch
- Name your app (e.g., "Databasement") and select your workspace
- Go to Incoming Webhooks and toggle it on
- Click Add New Webhook to Workspace
- Select the channel where you want notifications
- Copy the webhook URL and paste it in the Configuration page
Discord
To receive failure notifications in Discord, you need a bot token and a channel ID.
Creating a Discord Bot
- Go to Discord Developer Portal
- Click New Application and give it a name (e.g., "Databasement")
- Go to Bot in the sidebar and click Add Bot
- Under Token, click Copy to get your bot token
- Go to OAuth2 > URL Generator
- Select scopes:
bot - Select bot permissions:
Send Messages,Embed Links - Copy the generated URL and open it to invite the bot to your server
Getting a Channel ID
- Open Discord and go to User Settings > Advanced
- Enable Developer Mode
- Right-click the channel where you want notifications
- Click Copy Channel ID
Enter both the Bot Token and Channel ID on the Configuration page.
Telegram
To receive failure notifications via Telegram, you need a bot token and a chat ID.
Creating a Telegram Bot
- Open Telegram and search for @BotFather
- Send
/newbotand follow the prompts to name your bot - BotFather will give you a Bot Token — copy it
Getting a Chat ID
- Add your bot to the group or start a direct chat with it
- Send a message to the bot
- Open
https://api.telegram.org/bot<YOUR_BOT_TOKEN>/getUpdatesin a browser - Find the
chat.idvalue in the JSON response
Enter both the Bot Token and Chat ID on the Configuration page.
Pushover
Pushover delivers push notifications to your phone and desktop.
- Create an account at pushover.net
- Copy your User Key from the dashboard
- Go to Create an Application/API Token
- Name it (e.g., "Databasement") and copy the App Token
Enter both the App Token and User Key on the Configuration page.
Gotify
Gotify is a self-hosted push notification server.
- Log in to your Gotify server
- Go to Apps and create a new application (e.g., "Databasement")
- Copy the App Token
Enter your Gotify Server URL (e.g., https://gotify.example.com) and the App Token on the Configuration page.
Webhook
Send failure notifications as JSON payloads to any HTTP endpoint.
Enter your Webhook URL on the Configuration page. Optionally, provide a Webhook Secret to authenticate requests via the X-Webhook-Token header.
Request Format
Notifications are sent as POST requests with a JSON body:
{
"event": "BackupFailedNotification",
"title": "Backup Failed: Production DB",
"body": "A backup job has failed.",
"fields": {
"Server": "Production DB",
"Database": "myapp"
},
"error": "Connection refused",
"action_url": "https://your-instance.com/backup-jobs/...",
"timestamp": "2025-01-15T02:00:00+00:00"
}
Headers
| Header | Description |
|---|---|
Content-Type | application/json |
X-Webhook-Token | The configured secret (only if a secret is configured) |
Tip: Using with Apprise
The webhook channel can be pointed at an Apprise API endpoint to relay notifications to 100+ services (Ntfy, Matrix, Mattermost, etc.). Set the Apprise stateless endpoint (e.g., https://apprise.example.com/notify/) as your Webhook URL.
What Gets Notified
Notifications are sent only for failures:
- Backup failures: When a scheduled or manual backup fails
- Restore failures: When a restore operation fails
- Missing snapshots: When snapshot file verification detects missing backup files on storage volumes
Successful operations do not trigger notifications.
Notification Content
Each notification includes:
- Server name
- Database name
- Error message
- Timestamp
- Direct link to the failed job details