Updated Notifiers (markdown)

master
Hunter Long 2018-09-11 19:18:02 -07:00
parent 3a562dc17a
commit c5f3c59980
1 changed files with 13 additions and 2 deletions

@ -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