The discard notifier discards all notifications.
You can’t create discard notifiers from within the Chronosphere Observability
Platform interface.
Select from the following methods to create a discard notifier.
To create a discard notifier using Chronoctl:
-
Define the resource definition for your discard notifier:
api_version: v1/config
kind: Notifier
spec:
name: NAME
slug: SLUG
discard: true
Replace the following:
NAME: A descriptive name, such as Example discard.
SLUG: A unique identifier, such as example-discard.
-
Apply the changes:
chronoctl apply -f FILE_NAME.yaml
Replace FILE_NAME with the name of your notifier YAML file.
To create a discard notifier using Terraform:
-
Create a discard notifier with Terraform by using the
chronosphere_blackhole_alert_notifier type followed by a name in a resource
declaration:
resource "chronosphere_blackhole_alert_notifier" "discard" {
name = "Example discard"
}
-
Run
terraform apply to create the notifier resource.
To complete this action with the Chronosphere API, use the
CreateNotifier
endpoint.Because the Chronosphere API requires authentication, include an API token with your
curl request, as shown in the following example. For more details, see
Create an API token.export CHRONOSPHERE_API_TOKEN="TOKEN"
export CHRONOSPHERE_DOMAIN="INSTANCE.chronosphere.io"
curl -H "API-Token: ${CHRONOSPHERE_API_TOKEN}" \
-X METHOD "https://${CHRONOSPHERE_DOMAIN}/ENDPOINT_PATH"
Replace the following:
TOKEN: Your API token.
INSTANCE: The subdomain name for your organization’s Observability Platform instance.
METHOD: The HTTP method to use with the request, such as GET or POST.
ENDPOINT_PATH: The specific endpoint you want to access.