mirror of https://github.com/statping/statping
Updated Notifiers (markdown)
parent
3a562dc17a
commit
c5f3c59980
15
Notifiers.md
15
Notifiers.md
|
@ -6,7 +6,7 @@ Statup includes multiple Notifiers to alert you when your services are offline.
|
|||
- Must create and add your notifier variable in `init()`
|
||||
- Should have a form for user to input their variables/keys. `Form: []notifier.NotificationForm`
|
||||
|
||||
## Notification Interface
|
||||
## Notifier Interface
|
||||
Statup has the `Notifier` interface which you'll need to include in your notifier. Below is the current interface.
|
||||
```go
|
||||
// Notifier interface is required to create a new Notifier
|
||||
|
@ -31,4 +31,15 @@ type BasicEvents interface {
|
|||
// OnFailure is triggered when a service is failing
|
||||
OnFailure(*types.Service, *types.Failure)
|
||||
}
|
||||
```
|
||||
```
|
||||
|
||||
## Notifier Form
|
||||
Include a form with your notifier so other users can save API keys, username, passwords, and other values.
|
||||
|
||||
#### Accepted DbField Values
|
||||
- `host` used for a URL or API endpoint
|
||||
- `host` used for a URL or API endpoint
|
||||
- `host` used for a URL or API endpoint
|
||||
- `host` used for a URL or API endpoint
|
||||
- `host` used for a URL or API endpoint
|
||||
- `host` used for a URL or API endpoint
|
Loading…
Reference in New Issue