alerta / nagios-alerta

Forward nagios alerts to the alerta monitoring system
http://alerta.io
MIT License
23 stars 15 forks source link

Add Customer field to use Customer Views #26

Closed SergioRamirezIbanez closed 6 years ago

satterly commented 6 years ago

Thanks for the PR but the customer attribute can not be set this way. It can only be set by the Alerta API on receiving an alert. It will be set based on the customer associated with the API key used to authenticate the HTTP request to create the alert. If this doesn't make sense let me know.

satterly commented 6 years ago

I've just realised this isn't strictly true. If you use an Admin API key you can override the customer attribute. I'll reopen and review your PR. Sorry.

satterly commented 6 years ago

I've tested this PR and it is possible to set the customer attribute for alerts if you have an "admin" API key and at least Alerta API server version 5.2.0. Good work. Thanks! 👍