Send ntfy notifications
This commit is contained in:
parent
77a72329a8
commit
bdcc0def42
10 changed files with 289 additions and 44 deletions
23
src/notifications/ntfy/config.rs
Normal file
23
src/notifications/ntfy/config.rs
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// Configuration for the ntfy notification service
|
||||
#[derive(Debug, Serialize, Deserialize)]
|
||||
pub struct NtfyConfig {
|
||||
/// Whether to enable the ntfy notification service
|
||||
#[serde(default)]
|
||||
pub enable: bool,
|
||||
|
||||
/// The host URL of the ntfy server
|
||||
pub host: String,
|
||||
|
||||
/// The username for authentication (optional)
|
||||
#[serde(default)]
|
||||
pub username: Option<String>,
|
||||
|
||||
/// The password for authentication (optional)
|
||||
#[serde(default)]
|
||||
pub password: Option<String>,
|
||||
|
||||
/// The topic to publish notifications to
|
||||
pub topic: String,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue