Creates a new disk event rule.
The request consumes and produces an application/json
payload.
POST | SaaS | https://{your-environment-id}.live.dynatrace.com/api/config/v1/anomalyDetection/diskEvents |
Environment ActiveGate | https://{your-activegate-domain}:9999/e/{your-environment-id}/api/config/v1/anomalyDetection/diskEvents |
To execute this request, you need an access token with WriteConfig
scope.
To learn how to obtain and use it, see Tokens and authentication.
JSON body of the request. Contains parameters of the new disk event rule.
DiskEventAnomalyDetectionConfig
objectNarrows the rule usage down to disks, matching the specified criteria.
Disk event rule enabled/disabled.
Narrows the rule usage down to disks that run on hosts that themselves run on the specified host group.
The ID of the disk event rule.
The metric to monitor.
LOW_DISK_SPACE
LOW_INODES
READ_TIME_EXCEEDING
WRITE_TIME_EXCEEDING
The name of the disk event rule.
The number of samples to evaluate.
The threshold to trigger disk event.
LowDiskSpace
or LowInodes
metrics.ReadTimeExceeding
or WriteTimeExceeding
metrics.The number of samples that must violate the threshold to trigger an event. Must not exceed the number of evaluated samples.
DiskNameFilter
objectNarrows the rule usage down to disks, matching the specified criteria.
Comparison operator.
CONTAINS
DOES_NOT_CONTAIN
DOES_NOT_EQUAL
DOES_NOT_START_WITH
EQUALS
STARTS_WITH
Value to compare to.
ConfigurationMetadata
objectMetadata useful for debugging
Dynatrace version.
A sorted list of the version numbers of the configuration.
A sorted list of version numbers of the configuration.
TagFilter
objectA tag-based filter of monitored entities.
The origin of the tag, such as AWS or Cloud Foundry.
Custom tags use the CONTEXTLESS
value.
AWS
AWS_GENERIC
AZURE
CLOUD_FOUNDRY
CONTEXTLESS
ENVIRONMENT
GOOGLE_CLOUD
KUBERNETES
The key of the tag.
Custom tags have the tag value here.
The value of the tag.
Not applicable to custom tags.
This is a model of the request body, showing the possible elements. It has to be adjusted for usage in an actual request.
{"diskNameFilter": {"operator": "CONTAINS","value": "string"},"enabled": true,"hostGroupId": "string","id": "string","metadata": {"clusterVersion": "1.192.1","configurationVersions": [4,2],"currentConfigurationVersions": ["1.0.4","1.23"]},"metric": "LOW_DISK_SPACE","name": "string","samples": 10,"tagFilters": [{"context": "AWS","key": "string","value": "string"}],"threshold": 1,"violatingSamples": 8}
Success. The new disk event rule has been created. The ID of the new disk event rule is returned.
EntityShortRepresentation
objectThe short representation of a Dynatrace entity.
A short description of the Dynatrace entity.
The ID of the Dynatrace entity.
The name of the Dynatrace entity.
{"description": "Dynatrace entity for the REST API example","id": "6a98d7bc-abb9-44f8-ae6a-73e68e71812a","name": "Dynatrace entity"}
We recommend that you validate the payload before submitting it with an actual request. A response code of 204 indicates a valid payload.
The request consumes an application/json
payload.
POST | SaaS | https://{your-environment-id}.live.dynatrace.com/api/config/v1/anomalyDetection/diskEvents/validator |
Environment ActiveGate | https://{your-activegate-domain}:9999/e/{your-environment-id}/api/config/v1/anomalyDetection/diskEvents/validator |
To execute this request, you need an access token with WriteConfig
scope.
To learn how to obtain and use it, see Tokens and authentication.
Validated. The submitted disk event rule is valid. Response doesn't have a body.
In this example, the request creates a new custom disk event rule named very slow disk. The rule triggers an alert for any disk whose name starts with C
and whose read time exceeds 200 milliseconds in 8 out of 10 samples.
The API token is passed in the Authorization header.
You can download or copy the example request body to try it out on your own.
curl -X POST \https://mySampleEnv.live.dynatrace.com/api/config/v1/anomalyDetection/diskEvents \-H 'Authorization: Api-Token dt0c01.abc123.abcdefjhij1234567890' \-H 'Content-Type: application/json' \-d '{"name": "very slow disk","enabled": true,"metric": "READ_TIME_EXCEEDING","threshold": 200,"samples": 10,"violatingSamples": 8,"diskNameFilter": {"operator": "STARTS_WITH","value": "C"},"tagFilters": []}'
https://mySampleEnv.live.dynatrace.com/api/config/v1/anomalyDetection/diskEvents
{"name": "very slow disk","enabled": true,"metric": "READ_TIME_EXCEEDING","threshold": 200,"samples": 10,"violatingSamples": 8,"diskNameFilter": {"operator": "STARTS_WITH","value": "C"},"tagFilters": []}
{"id": "fdd83212-9c08-44ba-a0cf-dbb471cd819a","name": "very slow disk"}
204
The new rule looks like this in the UI: