Class WebNotificationHook
java.lang.Object
com.azure.ai.metricsadvisor.administration.models.NotificationHook
com.azure.ai.metricsadvisor.administration.models.WebNotificationHook
A hook that describes web-hook based incident alerts notification.
-
Constructor Summary
ConstructorDescriptionWebNotificationHook
(String name, String endpoint) Create a new instance of WebNotificationHook. -
Method Summary
Modifier and TypeMethodDescriptionThe HTTPS client certificate to access the endpoint.The password of the HTTPS client certificate to access the endpoint.Gets the description for the Notification hook.Gets the web endpoint that receives incident alerts.Gets the external link url, this will be included in the notification sent to the users, this is usually a reference to any troubleshooting guide.Gets the HTTP headers to send while sending alert to the endpoint.getName()
Gets the name for the Notification hook.Gets the password to authenticate the endpoint.Gets the user name to authenticate the endpoint.Sets the user e-mails and clientIds with administrative rights to manage the hook.setClientCertificate
(String certificate, String password) Sets the HTTPS certificate to use to access the endpoint.setDescription
(String description) Sets web hook description.setEndPoint
(String endpoint) The web endpoint to notify incident alerts.setExternalLink
(String externalLink) Sets the customized external link, it will be included in the notification sent to the users, this is usually a reference to any troubleshooting guide.setHttpHeaders
(HttpHeaders httpHeaders) Sets the HTTP headers to send while sending alert to the endpoint.Sets web hook name.setUserCredentials
(String username, String password) Sets the credential to access the endpoint.Methods inherited from class com.azure.ai.metricsadvisor.administration.models.NotificationHook
getAdmins, getId
-
Constructor Details
-
WebNotificationHook
Create a new instance of WebNotificationHook.- Parameters:
name
- The web hook name.endpoint
- The web endpoint to notify incident alerts.
-
-
Method Details
-
getName
Description copied from class:NotificationHook
Gets the name for the Notification hook.- Specified by:
getName
in classNotificationHook
- Returns:
- The name.
-
getDescription
Description copied from class:NotificationHook
Gets the description for the Notification hook.- Specified by:
getDescription
in classNotificationHook
- Returns:
- The description.
-
getEndpoint
Gets the web endpoint that receives incident alerts.- Returns:
- The endpoint.
-
getExternalLink
Gets the external link url, this will be included in the notification sent to the users, this is usually a reference to any troubleshooting guide.- Returns:
- The external link.
-
getUsername
Gets the user name to authenticate the endpoint.- Returns:
- The user name.
-
getPassword
Gets the password to authenticate the endpoint.- Returns:
- The password.
-
getClientCertificate
The HTTPS client certificate to access the endpoint.- Returns:
- The client certificate.
-
getClientCertificatePassword
The password of the HTTPS client certificate to access the endpoint.- Returns:
- The client certificate password
-
getHttpHeaders
Gets the HTTP headers to send while sending alert to the endpoint.- Returns:
- The HTTP headers.
-
setEndPoint
The web endpoint to notify incident alerts.- Parameters:
endpoint
- The endpoint- Returns:
- The WebNotificationHook object itself.
-
setName
Sets web hook name.- Parameters:
name
- The web hook name.- Returns:
- The WebNotificationHook object itself.
-
setDescription
Sets web hook description.- Parameters:
description
- The web hook description.- Returns:
- The WebNotificationHook object itself.
-
setExternalLink
Sets the customized external link, it will be included in the notification sent to the users, this is usually a reference to any troubleshooting guide.- Parameters:
externalLink
- The customized link.- Returns:
- The WebNotificationHook object itself.
-
setUserCredentials
Sets the credential to access the endpoint.- Parameters:
username
- The user name.password
- The password.- Returns:
- The WebNotificationHook object itself.
-
setClientCertificate
Sets the HTTPS certificate to use to access the endpoint.- Parameters:
certificate
- The certificate.password
- The certificate password.- Returns:
- The WebNotificationHook object itself.
-
setHttpHeaders
Sets the HTTP headers to send while sending alert to the endpoint.- Parameters:
httpHeaders
- The HTTP headers.- Returns:
- The WebNotificationHook object itself.
-
setAdmins
Sets the user e-mails and clientIds with administrative rights to manage the hook.The administrators have total control over the hook, being allowed to update or delete the hook. Each element in this list represents a user with administrator access, but the value of each string element as either user email address or clientId uniquely identifying the user service principal.
- Parameters:
admins
- A list containing email or clientId of admins- Returns:
- The WebNotificationHook object itself.
-