Time to upgrade! NAM is scheduled for end of support. It's time to move to Dynatrace our all-in-one software intelligence platform.

Alerts API - PUT specified alert definition

Applies to NAM 2019+

Updates alert with specified name.

PUT
  • url https://{console-host}:{console-port}/cxf/api/v1/cxf/api/v1/config/alerts/definitions/{name}

Parameters

Parameter Type Description In Required
name string path required
body AlertPublicRest

Created user object

body optional

The AlertPublicRest object

Element Type Description Required
name string

Alert name. Must be unique if you want to use the API.

required
type string
  • METRIC_ALM = Real user performance (probe)
  • TRANSMETRIC_ALM = Operation sequences
  • TRANSACTIVE_METRIC_ALM = Enterprise synthetic
  • CITRIXMETRIC_ALM = Citrix/WTS hardware
  • LINK_ALM = Network link
  • METRIC_ALM_P2P = Internetwork traffic
  • TIERMETRIC_ALM = Application user experience
  • AMD_DRIVER_ALM = NAM Probe driver statistics
  • AMD_INTERFACE_ALM = NAM Probe interface statistics
  • AMD_SERVER_ALM = NAM Probe server statistics
  • ESM_METRIC_ALM = Agent health statistics (obsolete)
  • SYSTEM = System Maintanance (this type is for internal purposes only, it is not allowed in API)
The type element can hold these values.
optional
description string optional
definition AlertDefinition required
detectionSettings AlertDetectionSettings optional
propagationSettings AlertPropagationSettings optional
notificationSettings AlertNotificationSettings optional
recipientIds integer[]

Identifiers of recipients that will receive alert notifications.

optional
namServers string[]

List of NAM Servers on which the alert definition resides.

optional

The AlertNotificationSettings object

Element Type Description Required
disabled boolean

If set to true, no notification will be send out of this alert.

optional
aggregated boolean

Aggregate notifications for this alert into a single email. Applies only to email notifications.

optional
message string

Type the message to send when the alert occurs. (To display metric/dimension values or use macros, the mnemonics enclosed in {} need to be used. The format is different than in the UI).

optional
subject string

Email subject.

optional
snmpmessage string

Message for SNMP traps.

optional

The AlertPropagationSettings object

  • entrySignalProperties = Raise alert after conditions are met for the specified number of consecutive intervals
  • exitSignalProperties = Cancel alert after conditions are not met for the specified number of consecutive intervals
  • abortSignalProperties = Abort alert after the specified time
  • recallSignalProperties = Reissue alert after the specified number of intervals
Element Type Description Required
entrySignalProperties AlertSignalPropertiesIntervals optional
exitSignalProperties AlertSignalPropertiesIntervals optional
abortSignalProperties AlertSignalPropertiesMinutes optional
recallSignalProperties AlertSignalPropertiesIntervals optional
notifyNoTraffic string

Defines what to do when no traffic was observed:

  • NOTIFIABLE_ON_RAISING = The alert conditions are met
  • NOTIFIABLE_ON_CANCELLING = The alert conditions are not met
  • UNNOTIFIABLE = Perform no action and wait for traffic
The notifyNoTraffic element can hold these values.
optional

The AlertSignalPropertiesMinutes object

Element Type Description Required
minutes integer optional
description string optional

The AlertSignalPropertiesIntervals object

Element Type Description Required
intervals integer optional
description string optional

The AlertDetectionSettings object

Element Type Description Required
disabled boolean

Is alert disabled?

optional
timeRange integer

Note: 1 is a special value meaning 1 monitoring interval. Other values specify a time range in minutes.

The timeRange element can hold these values.
optional
frequency integer

Note: 1 is a special value meaning 1 monitoring interval. Other values specify a time range in minutes. Frequency must be less than or equal to timeRange.

The frequency element can hold these values.
optional

The AlertDefinition object

Element Type Description Required
dimensionConditions AlertCondition[] optional
metricConditions AlertCondition[] optional
outputFilter string optional

The AlertCondition object

Element Type Description Required
id string

Metric or dimension ID.

required
filter string

Filter value for the specified metric or dimension. For metrics, it should start with <, >, <=, or >=

optional
filterType string
  • NONE = for internal purposes only. Do not use
  • DIMENSION = Dimension and Filter
  • DIMENSION_FILTER_ONLY = Only filtering for dimension
  • METRIC_VALUE = Metric value type condition
  • METRIC_BASELINE_ABSOLUTE = Absolute baseline type condition
  • METRIC_BASELINE_RELATIVE = Relative baseline type condition
  • METRIC_AUXILARY = Auxiliary metric
The filterType element can hold these values.
optional
negateFilter boolean

If true, the value of the filter will be negated.

optional
expression string

Compound metric expression. Ignored for dimension type conditions.

optional

Possible values

Possible values for the notifyNoTraffic element in the AlertPropagationSettings object:

  • NOTIFIABLE_ON_RAISING
  • NOTIFIABLE_ON_CANCELLING
  • UNNOTIFIABLE

Possible values for the frequency element in the AlertDetectionSettings object:

  • 1
  • 10
  • 15
  • 30
  • 60

Possible values for the timeRange element in the AlertDetectionSettings object:

  • 1
  • 10
  • 15
  • 30
  • 60

Possible values for the filterType element in the AlertCondition object:

  • NONE
  • DIMENSION
  • DIMENSION_FILTER_ONLY
  • METRIC_VALUE
  • METRIC_BASELINE_ABSOLUTE
  • METRIC_BASELINE_RELATIVE
  • METRIC_AUXILARY

Possible values for the type element in the AlertPublicRest object:

  • METRIC_ALM
  • TRANSMETRIC_ALM
  • TRANSACTIVE_METRIC_ALM
  • GOMEZSTEP_METRIC_ALM
  • GOMEZTEST_METRIC_ALM
  • CITRIXMETRIC_ALM
  • LINK_ALM
  • METRIC_ALM_P2P
  • TIERMETRIC_ALM
  • AMD_DRIVER_ALM
  • AMD_INTERFACE_ALM
  • AMD_SERVER_ALM
  • ESM_METRIC_ALM
  • SYSTEM

Response format

The AlertPublicRestErrorResponse object

Element Type Description
errorCode string
errorMessage string

The AlertPublicRest object

Element Type Description
name string

Alert name. Must be unique if you want to use the API.

type string
  • METRIC_ALM = Real user performance (probe)
  • TRANSMETRIC_ALM = Operation sequences
  • TRANSACTIVE_METRIC_ALM = Enterprise synthetic
  • CITRIXMETRIC_ALM = Citrix/WTS hardware
  • LINK_ALM = Network link
  • METRIC_ALM_P2P = Internetwork traffic
  • TIERMETRIC_ALM = Application user experience
  • AMD_DRIVER_ALM = NAM Probe driver statistics
  • AMD_INTERFACE_ALM = NAM Probe interface statistics
  • AMD_SERVER_ALM = NAM Probe server statistics
  • ESM_METRIC_ALM = Agent health statistics (obsolete)
  • SYSTEM = System Maintanance (this type is for internal purposes only, it is not allowed in API)
The type element can hold these values.
description string
definition AlertDefinition
detectionSettings AlertDetectionSettings
propagationSettings AlertPropagationSettings
notificationSettings AlertNotificationSettings
recipientIds integer[]

Identifiers of recipients that will receive alert notifications.

namServers string[]

List of NAM Servers on which the alert definition resides.

The AlertNotificationSettings object

Element Type Description
disabled boolean

If set to true, no notification will be send out of this alert.

aggregated boolean

Aggregate notifications for this alert into a single email. Applies only to email notifications.

message string

Type the message to send when the alert occurs. (To display metric/dimension values or use macros, the mnemonics enclosed in {} need to be used. The format is different than in the UI).

subject string

Email subject.

snmpmessage string

Message for SNMP traps.

The AlertPropagationSettings object

  • entrySignalProperties = Raise alert after conditions are met for the specified number of consecutive intervals
  • exitSignalProperties = Cancel alert after conditions are not met for the specified number of consecutive intervals
  • abortSignalProperties = Abort alert after the specified time
  • recallSignalProperties = Reissue alert after the specified number of intervals
Element Type Description
entrySignalProperties AlertSignalPropertiesIntervals
exitSignalProperties AlertSignalPropertiesIntervals
abortSignalProperties AlertSignalPropertiesMinutes
recallSignalProperties AlertSignalPropertiesIntervals
notifyNoTraffic string

Defines what to do when no traffic was observed:

  • NOTIFIABLE_ON_RAISING = The alert conditions are met
  • NOTIFIABLE_ON_CANCELLING = The alert conditions are not met
  • UNNOTIFIABLE = Perform no action and wait for traffic
The notifyNoTraffic element can hold these values.

The AlertSignalPropertiesMinutes object

Element Type Description
minutes integer
description string

The AlertSignalPropertiesIntervals object

Element Type Description
intervals integer
description string

The AlertDetectionSettings object

Element Type Description
disabled boolean

Is alert disabled?

timeRange integer

Note: 1 is a special value meaning 1 monitoring interval. Other values specify a time range in minutes.

The timeRange element can hold these values.
frequency integer

Note: 1 is a special value meaning 1 monitoring interval. Other values specify a time range in minutes. Frequency must be less than or equal to timeRange.

The frequency element can hold these values.

The AlertDefinition object

Element Type Description
dimensionConditions AlertCondition[]
metricConditions AlertCondition[]
outputFilter string

The AlertCondition object

Element Type Description
id string

Metric or dimension ID.

filter string

Filter value for the specified metric or dimension. For metrics, it should start with <, >, <=, or >=

filterType string
  • NONE = for internal purposes only. Do not use
  • DIMENSION = Dimension and Filter
  • DIMENSION_FILTER_ONLY = Only filtering for dimension
  • METRIC_VALUE = Metric value type condition
  • METRIC_BASELINE_ABSOLUTE = Absolute baseline type condition
  • METRIC_BASELINE_RELATIVE = Relative baseline type condition
  • METRIC_AUXILARY = Auxiliary metric
The filterType element can hold these values.
negateFilter boolean

If true, the value of the filter will be negated.

expression string

Compound metric expression. Ignored for dimension type conditions.

Possible values

Possible values for the notifyNoTraffic element in the AlertPropagationSettings object:

  • NOTIFIABLE_ON_RAISING
  • NOTIFIABLE_ON_CANCELLING
  • UNNOTIFIABLE

Possible values for the frequency element in the AlertDetectionSettings object:

  • 1
  • 10
  • 15
  • 30
  • 60

Possible values for the timeRange element in the AlertDetectionSettings object:

  • 1
  • 10
  • 15
  • 30
  • 60

Possible values for the filterType element in the AlertCondition object:

  • NONE
  • DIMENSION
  • DIMENSION_FILTER_ONLY
  • METRIC_VALUE
  • METRIC_BASELINE_ABSOLUTE
  • METRIC_BASELINE_RELATIVE
  • METRIC_AUXILARY

Possible values for the type element in the AlertPublicRest object:

  • METRIC_ALM
  • TRANSMETRIC_ALM
  • TRANSACTIVE_METRIC_ALM
  • GOMEZSTEP_METRIC_ALM
  • GOMEZTEST_METRIC_ALM
  • CITRIXMETRIC_ALM
  • LINK_ALM
  • METRIC_ALM_P2P
  • TIERMETRIC_ALM
  • AMD_DRIVER_ALM
  • AMD_INTERFACE_ALM
  • AMD_SERVER_ALM
  • ESM_METRIC_ALM
  • SYSTEM

Response codes

Code Description
200

The alert has been updated.

400

The request was invalid.

404

The alert was not found.

409

More than one alert with the specified name was found.

503

Service unavailable. This also happens when the NAM Console cannot collect metadata from NAM Servers.

Example

In this example, we GET an alert definition (alert name "Application performance of an application (front-end)"), edit the definition, and PUT the edited definition.

  1. Issue a GET https://172.18.148.231:4183/cxf/api/v1/config/alerts/definitions/Application performance of an application (front-end) request.

  2. Copy and edit the response, which will be the definition of the alert named in the GET request.

  3. Edit the alert definition and PUT it back to the NAM Console as an application/json payload. In this example, we used Postman to issue a PUT with an edited alert definition (name changed) in the application/json payload.

  4. The edited alert will be listed on the NAM Console Alerts management page (Monitoring > Alerts) under the new name. In practice, you could of course make other configuration changes before you PUT it, and you could use your own scripts to make multiple PUTs.