ntfy Attributes¶
Configuring ntfy is optional but can allow you to send the webhooks straight to ntfy.
Setup¶
Users can either use the public ntfy server, or host their own ntfy server.
Retrieving Access Token and Topic¶
Using the Public Server¶
- Visit https://ntfy.sh/login and login or sign up for an account (it's free).
- Select "Account" from the side menu and scroll to "Access Tokens" to generate an access token.
- Copy the access token and paste it into the
tokenattribute in your config file. Enterhttps://ntfy.shinto theurlattribute. - Click "Subscribe to topic" from the side menu and enter a topic name.
- Pro subscribers can reserve specific topics, but any free tier user can subscribe and publish to any non-reserved topic.
- Common topics such as
kometaare likely already reserved or at least used by other public ntfy users (and these topics may be visible to the general public). It's recommended to use a random topic name to keep your notifications semi-private. - Enter the topic name into the
topicattribute in the config file.
Using a Self-Hosted Server¶
If you are a standard (non-admin) user of a ntfy server other than the official one, you can follow the same steps as above, but with the server URL and token provided by the server.
If you are an admin of your own ntfy server, you can follow these steps:
- Follow the installation instructions to set up your own ntfy server.
- Follow the same steps above for creating an account and access token, or use the
ntfycommand line tool to create a user and generate an access token. - Follow the same steps as above for generating/reserving a topic, but with the server URL and token provided by your server.
Configuring ntfy in the Config File¶
Use the URL, topic and token to configure ntfy in the root of the config file:
config.yml ntfy sample
ntfy:
url: https://ntfy.sh # or a different ntfy server URL
token: tk_thisismyaccesstoken
topic: kometa # or a different topic name
| Attribute | Allowed Values | Required |
|---|---|---|
url |
ntfy Server Url. | |
token |
ntfy User Access Token. | |
topic |
ntfy Topic. |
Once you have added the configuration data to your config.yml, you can add ntfy to any webhook to
send that notification to ntfy.