Skip to content

Notifications

Yuzerion edited this page Feb 1, 2025 · 5 revisions

Notifications

What is a Notification?

A notification is a type of message sent to users to inform them about an event, update, or action (currently used for notifying app health status changes).

Enabling Notifications

To enable notifications, you need to configure it in your config.yml file. Follow these steps:

  1. Open config/config.yml: Open it with WebUI config editor or a text editor.

  2. Add Gotify Notification Configuration:

    notification:
      - name: gotify
        provider: gotify
        url: https://gotify.my.site
        token: abcdef.12345
  3. Add Ntfy Notification Configuration:

    notification:
      - name: ntfy
        provider: ntfy
        url: https://ntfy.domain.com
        topic: some-topic
        # token: xxx # if your Ntfy is configured with access tokens
  4. Add Discord Notification Configuration:

    notification:
      - name: discord
        provider: webhook
        url: https://discord.com/api/webhooks/...
        template: discord

Gotify Provider

  • Set a name for your provider (e.g., gotify).
  • Set the provider to gotify.
  • Set the url to the address where Gotify is hosted.
  • Set the token which is used to authenticate.

Ntfy Provider

  • Set a name for your provider (e.g., ntfy).
  • Set the provider to ntfy.
  • Set the url to the address (without topic) where Ntfy is hosted.
  • Set the topic which is the message will be sent to.
  • Set the token if your server is configured with access tokens.

Discord Provider

  • Set a name for your provider (e.g., discord).
  • Set the provider to webhook.
  • Set the url which is the webhook address for your Discord channel.
  • Set the template to discord to use Discord formatting.

Other webhook providers

  • Set a name for your provider (e.g., slack).
  • Set the provider to webhook.
  • Set the url which is the webhook address for your Slack channel.
  • Set the payload to appropriate JSON body for your webhook provider.
  • Set the token if your provider requires authentication.

WebUI config example

Gotify Notification Discord Notification

Full Webhook documentation

Webhook fields

Field Description Required Allowed values
name name of the provider Yes
provider Yes webhook
url webhook URL Yes Full URL
template webhook template No empty, discord
token webhook token No
payload webhook payload No (if template is used) valid json
method webhook request method No GET POST PUT
mime_type MIME type No
color_mode color mode No hex dec

Available Payload Variables

When using a webhook payload, you can include the following variables:

  • $title: Title of the message.
  • $message: Message in Markdown format.
  • $fields: Additional fields in JSON format.
  • $color: Color of the message in hex (e.g., #ff0000) or dec (e.g., 16711680).