Attach database backup notification channel

Attach one of your notification channels to a database backup.


POST/api/backups/database/{databaseBackupId}/notification-channels

Attach database backup notification channel

This endpoint attaches a notification channel to the database backup. You can attach your own notification channels, use list notification channels to find their ids. To attach a channel to more than one location, call this endpoint once per location. To switch to another channel, detach the current one and attach the new one.

The response contains every channel attached to the database backup.

Required parameters

  • Name
    channel
    Type
    integer
    Description

    The id of one of your notification channels.

  • Name
    location
    Type
    string
    Description

    When the channel is notified: before-backup (the backup is starting), after-backup (the backup finished) or failed-backup (the backup failed).

Request

POST
/api/backups/database/{databaseBackupId}/notification-channels
curl -X POST "https://ploi.io/api/backups/database/1/notification-channels" \
  -H "Authorization: Bearer {token}" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{
    "channel": 12,
    "location": "failed-backup"
  }'

Response

{
  "data": [
    {
      "id": 12,
      "type": "slack",
      "label": "Ops alerts",
      "location": "failed-backup",
      "created_at": "2026-09-24 10:12:00"
    }
  ]
}