mongodbatlas logo
MongoDB Atlas v3.7.2, Mar 31 23

mongodbatlas.AlertConfiguration

Explore with Pulumi AI

mongodbatlas.AlertConfiguration provides an Alert Configuration resource to define the conditions that trigger an alert and the methods of notification within a MongoDB Atlas project.

NOTE: Groups and projects are synonymous terms. You may find groupId in the official documentation.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Mongodbatlas = Pulumi.Mongodbatlas;

return await Deployment.RunAsync(() => 
{
    var test = new Mongodbatlas.AlertConfiguration("test", new()
    {
        Enabled = true,
        EventType = "OUTSIDE_METRIC_THRESHOLD",
        Matchers = new[]
        {
            new Mongodbatlas.Inputs.AlertConfigurationMatcherArgs
            {
                FieldName = "HOSTNAME_AND_PORT",
                Operator = "EQUALS",
                Value = "SECONDARY",
            },
        },
        MetricThresholdConfig = new Mongodbatlas.Inputs.AlertConfigurationMetricThresholdConfigArgs
        {
            MetricName = "ASSERT_REGULAR",
            Mode = "AVERAGE",
            Operator = "LESS_THAN",
            Threshold = 99,
            Units = "RAW",
        },
        Notifications = new[]
        {
            new Mongodbatlas.Inputs.AlertConfigurationNotificationArgs
            {
                DelayMin = 0,
                EmailEnabled = true,
                IntervalMin = 5,
                Roles = new[]
                {
                    "GROUP_CHARTS_ADMIN",
                    "GROUP_CLUSTER_MANAGER",
                },
                SmsEnabled = false,
                TypeName = "GROUP",
            },
        },
        ProjectId = "<PROJECT-ID>",
    });

});
package main

import (
	"github.com/pulumi/pulumi-mongodbatlas/sdk/v3/go/mongodbatlas"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mongodbatlas.NewAlertConfiguration(ctx, "test", &mongodbatlas.AlertConfigurationArgs{
			Enabled:   pulumi.Bool(true),
			EventType: pulumi.String("OUTSIDE_METRIC_THRESHOLD"),
			Matchers: mongodbatlas.AlertConfigurationMatcherArray{
				&mongodbatlas.AlertConfigurationMatcherArgs{
					FieldName: pulumi.String("HOSTNAME_AND_PORT"),
					Operator:  pulumi.String("EQUALS"),
					Value:     pulumi.String("SECONDARY"),
				},
			},
			MetricThresholdConfig: &mongodbatlas.AlertConfigurationMetricThresholdConfigArgs{
				MetricName: pulumi.String("ASSERT_REGULAR"),
				Mode:       pulumi.String("AVERAGE"),
				Operator:   pulumi.String("LESS_THAN"),
				Threshold:  pulumi.Float64(99),
				Units:      pulumi.String("RAW"),
			},
			Notifications: mongodbatlas.AlertConfigurationNotificationArray{
				&mongodbatlas.AlertConfigurationNotificationArgs{
					DelayMin:     pulumi.Int(0),
					EmailEnabled: pulumi.Bool(true),
					IntervalMin:  pulumi.Int(5),
					Roles: pulumi.StringArray{
						pulumi.String("GROUP_CHARTS_ADMIN"),
						pulumi.String("GROUP_CLUSTER_MANAGER"),
					},
					SmsEnabled: pulumi.Bool(false),
					TypeName:   pulumi.String("GROUP"),
				},
			},
			ProjectId: pulumi.String("<PROJECT-ID>"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.mongodbatlas.AlertConfiguration;
import com.pulumi.mongodbatlas.AlertConfigurationArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationMatcherArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationMetricThresholdConfigArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationNotificationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var test = new AlertConfiguration("test", AlertConfigurationArgs.builder()        
            .enabled(true)
            .eventType("OUTSIDE_METRIC_THRESHOLD")
            .matchers(AlertConfigurationMatcherArgs.builder()
                .fieldName("HOSTNAME_AND_PORT")
                .operator("EQUALS")
                .value("SECONDARY")
                .build())
            .metricThresholdConfig(AlertConfigurationMetricThresholdConfigArgs.builder()
                .metricName("ASSERT_REGULAR")
                .mode("AVERAGE")
                .operator("LESS_THAN")
                .threshold(99)
                .units("RAW")
                .build())
            .notifications(AlertConfigurationNotificationArgs.builder()
                .delayMin(0)
                .emailEnabled(true)
                .intervalMin(5)
                .roles(                
                    "GROUP_CHARTS_ADMIN",
                    "GROUP_CLUSTER_MANAGER")
                .smsEnabled(false)
                .typeName("GROUP")
                .build())
            .projectId("<PROJECT-ID>")
            .build());

    }
}
import pulumi
import pulumi_mongodbatlas as mongodbatlas

test = mongodbatlas.AlertConfiguration("test",
    enabled=True,
    event_type="OUTSIDE_METRIC_THRESHOLD",
    matchers=[mongodbatlas.AlertConfigurationMatcherArgs(
        field_name="HOSTNAME_AND_PORT",
        operator="EQUALS",
        value="SECONDARY",
    )],
    metric_threshold_config=mongodbatlas.AlertConfigurationMetricThresholdConfigArgs(
        metric_name="ASSERT_REGULAR",
        mode="AVERAGE",
        operator="LESS_THAN",
        threshold=99,
        units="RAW",
    ),
    notifications=[mongodbatlas.AlertConfigurationNotificationArgs(
        delay_min=0,
        email_enabled=True,
        interval_min=5,
        roles=[
            "GROUP_CHARTS_ADMIN",
            "GROUP_CLUSTER_MANAGER",
        ],
        sms_enabled=False,
        type_name="GROUP",
    )],
    project_id="<PROJECT-ID>")
import * as pulumi from "@pulumi/pulumi";
import * as mongodbatlas from "@pulumi/mongodbatlas";

const test = new mongodbatlas.AlertConfiguration("test", {
    enabled: true,
    eventType: "OUTSIDE_METRIC_THRESHOLD",
    matchers: [{
        fieldName: "HOSTNAME_AND_PORT",
        operator: "EQUALS",
        value: "SECONDARY",
    }],
    metricThresholdConfig: {
        metricName: "ASSERT_REGULAR",
        mode: "AVERAGE",
        operator: "LESS_THAN",
        threshold: 99,
        units: "RAW",
    },
    notifications: [{
        delayMin: 0,
        emailEnabled: true,
        intervalMin: 5,
        roles: [
            "GROUP_CHARTS_ADMIN",
            "GROUP_CLUSTER_MANAGER",
        ],
        smsEnabled: false,
        typeName: "GROUP",
    }],
    projectId: "<PROJECT-ID>",
});
resources:
  test:
    type: mongodbatlas:AlertConfiguration
    properties:
      enabled: true
      eventType: OUTSIDE_METRIC_THRESHOLD
      matchers:
        - fieldName: HOSTNAME_AND_PORT
          operator: EQUALS
          value: SECONDARY
      metricThresholdConfig:
        metricName: ASSERT_REGULAR
        mode: AVERAGE
        operator: LESS_THAN
        threshold: 99
        units: RAW
      notifications:
        - delayMin: 0
          emailEnabled: true
          intervalMin: 5
          roles:
            - GROUP_CHARTS_ADMIN
            - GROUP_CLUSTER_MANAGER
          smsEnabled: false
          typeName: GROUP
      projectId: <PROJECT-ID>

In order to allow for a fast pace of change to alert variables some validations have been removed from this resource in order to unblock alert creation. Impacted areas have links to the MongoDB Atlas API documentation so always check it for the most current information: https://docs.atlas.mongodb.com/reference/api/alert-configurations-create-config/

using System.Collections.Generic;
using Pulumi;
using Mongodbatlas = Pulumi.Mongodbatlas;

return await Deployment.RunAsync(() => 
{
    var test = new Mongodbatlas.AlertConfiguration("test", new()
    {
        Enabled = true,
        EventType = "REPLICATION_OPLOG_WINDOW_RUNNING_OUT",
        Matchers = new[]
        {
            new Mongodbatlas.Inputs.AlertConfigurationMatcherArgs
            {
                FieldName = "HOSTNAME_AND_PORT",
                Operator = "EQUALS",
                Value = "SECONDARY",
            },
        },
        Notifications = new[]
        {
            new Mongodbatlas.Inputs.AlertConfigurationNotificationArgs
            {
                DelayMin = 0,
                EmailEnabled = true,
                IntervalMin = 5,
                Roles = new[]
                {
                    "GROUP_CHARTS_ADMIN",
                    "GROUP_CLUSTER_MANAGER",
                },
                SmsEnabled = false,
                TypeName = "GROUP",
            },
        },
        ProjectId = "<PROJECT-ID>",
        ThresholdConfig = new Mongodbatlas.Inputs.AlertConfigurationThresholdConfigArgs
        {
            Operator = "LESS_THAN",
            Threshold = 1,
            Units = "HOURS",
        },
    });

});
package main

import (
	"github.com/pulumi/pulumi-mongodbatlas/sdk/v3/go/mongodbatlas"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mongodbatlas.NewAlertConfiguration(ctx, "test", &mongodbatlas.AlertConfigurationArgs{
			Enabled:   pulumi.Bool(true),
			EventType: pulumi.String("REPLICATION_OPLOG_WINDOW_RUNNING_OUT"),
			Matchers: mongodbatlas.AlertConfigurationMatcherArray{
				&mongodbatlas.AlertConfigurationMatcherArgs{
					FieldName: pulumi.String("HOSTNAME_AND_PORT"),
					Operator:  pulumi.String("EQUALS"),
					Value:     pulumi.String("SECONDARY"),
				},
			},
			Notifications: mongodbatlas.AlertConfigurationNotificationArray{
				&mongodbatlas.AlertConfigurationNotificationArgs{
					DelayMin:     pulumi.Int(0),
					EmailEnabled: pulumi.Bool(true),
					IntervalMin:  pulumi.Int(5),
					Roles: pulumi.StringArray{
						pulumi.String("GROUP_CHARTS_ADMIN"),
						pulumi.String("GROUP_CLUSTER_MANAGER"),
					},
					SmsEnabled: pulumi.Bool(false),
					TypeName:   pulumi.String("GROUP"),
				},
			},
			ProjectId: pulumi.String("<PROJECT-ID>"),
			ThresholdConfig: &mongodbatlas.AlertConfigurationThresholdConfigArgs{
				Operator:  pulumi.String("LESS_THAN"),
				Threshold: pulumi.Float64(1),
				Units:     pulumi.String("HOURS"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.mongodbatlas.AlertConfiguration;
import com.pulumi.mongodbatlas.AlertConfigurationArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationMatcherArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationNotificationArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationThresholdConfigArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var test = new AlertConfiguration("test", AlertConfigurationArgs.builder()        
            .enabled(true)
            .eventType("REPLICATION_OPLOG_WINDOW_RUNNING_OUT")
            .matchers(AlertConfigurationMatcherArgs.builder()
                .fieldName("HOSTNAME_AND_PORT")
                .operator("EQUALS")
                .value("SECONDARY")
                .build())
            .notifications(AlertConfigurationNotificationArgs.builder()
                .delayMin(0)
                .emailEnabled(true)
                .intervalMin(5)
                .roles(                
                    "GROUP_CHARTS_ADMIN",
                    "GROUP_CLUSTER_MANAGER")
                .smsEnabled(false)
                .typeName("GROUP")
                .build())
            .projectId("<PROJECT-ID>")
            .thresholdConfig(AlertConfigurationThresholdConfigArgs.builder()
                .operator("LESS_THAN")
                .threshold(1)
                .units("HOURS")
                .build())
            .build());

    }
}
import pulumi
import pulumi_mongodbatlas as mongodbatlas

test = mongodbatlas.AlertConfiguration("test",
    enabled=True,
    event_type="REPLICATION_OPLOG_WINDOW_RUNNING_OUT",
    matchers=[mongodbatlas.AlertConfigurationMatcherArgs(
        field_name="HOSTNAME_AND_PORT",
        operator="EQUALS",
        value="SECONDARY",
    )],
    notifications=[mongodbatlas.AlertConfigurationNotificationArgs(
        delay_min=0,
        email_enabled=True,
        interval_min=5,
        roles=[
            "GROUP_CHARTS_ADMIN",
            "GROUP_CLUSTER_MANAGER",
        ],
        sms_enabled=False,
        type_name="GROUP",
    )],
    project_id="<PROJECT-ID>",
    threshold_config=mongodbatlas.AlertConfigurationThresholdConfigArgs(
        operator="LESS_THAN",
        threshold=1,
        units="HOURS",
    ))
import * as pulumi from "@pulumi/pulumi";
import * as mongodbatlas from "@pulumi/mongodbatlas";

const test = new mongodbatlas.AlertConfiguration("test", {
    enabled: true,
    eventType: "REPLICATION_OPLOG_WINDOW_RUNNING_OUT",
    matchers: [{
        fieldName: "HOSTNAME_AND_PORT",
        operator: "EQUALS",
        value: "SECONDARY",
    }],
    notifications: [{
        delayMin: 0,
        emailEnabled: true,
        intervalMin: 5,
        roles: [
            "GROUP_CHARTS_ADMIN",
            "GROUP_CLUSTER_MANAGER",
        ],
        smsEnabled: false,
        typeName: "GROUP",
    }],
    projectId: "<PROJECT-ID>",
    thresholdConfig: {
        operator: "LESS_THAN",
        threshold: 1,
        units: "HOURS",
    },
});
resources:
  test:
    type: mongodbatlas:AlertConfiguration
    properties:
      enabled: true
      eventType: REPLICATION_OPLOG_WINDOW_RUNNING_OUT
      matchers:
        - fieldName: HOSTNAME_AND_PORT
          operator: EQUALS
          value: SECONDARY
      notifications:
        - delayMin: 0
          emailEnabled: true
          intervalMin: 5
          roles:
            - GROUP_CHARTS_ADMIN
            - GROUP_CLUSTER_MANAGER
          smsEnabled: false
          typeName: GROUP
      projectId: <PROJECT-ID>
      thresholdConfig:
        operator: LESS_THAN
        threshold: 1
        units: HOURS

Create an alert with two notifications using Email and SMS

using System.Collections.Generic;
using Pulumi;
using Mongodbatlas = Pulumi.Mongodbatlas;

return await Deployment.RunAsync(() => 
{
    var test = new Mongodbatlas.AlertConfiguration("test", new()
    {
        Enabled = true,
        EventType = "OUTSIDE_METRIC_THRESHOLD",
        Matchers = new[]
        {
            new Mongodbatlas.Inputs.AlertConfigurationMatcherArgs
            {
                FieldName = "HOSTNAME_AND_PORT",
                Operator = "EQUALS",
                Value = "SECONDARY",
            },
        },
        MetricThresholdConfig = new Mongodbatlas.Inputs.AlertConfigurationMetricThresholdConfigArgs
        {
            MetricName = "ASSERT_REGULAR",
            Mode = "AVERAGE",
            Operator = "LESS_THAN",
            Threshold = 99,
            Units = "RAW",
        },
        Notifications = new[]
        {
            new Mongodbatlas.Inputs.AlertConfigurationNotificationArgs
            {
                DelayMin = 0,
                EmailEnabled = true,
                IntervalMin = 5,
                Roles = new[]
                {
                    "GROUP_DATA_ACCESS_READ_ONLY",
                    "GROUP_CLUSTER_MANAGER",
                    "GROUP_DATA_ACCESS_ADMIN",
                },
                SmsEnabled = false,
                TypeName = "GROUP",
            },
            new Mongodbatlas.Inputs.AlertConfigurationNotificationArgs
            {
                DelayMin = 0,
                EmailEnabled = false,
                IntervalMin = 5,
                SmsEnabled = true,
                TypeName = "ORG",
            },
        },
        ProjectId = "PROJECT ID",
    });

});
package main

import (
	"github.com/pulumi/pulumi-mongodbatlas/sdk/v3/go/mongodbatlas"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mongodbatlas.NewAlertConfiguration(ctx, "test", &mongodbatlas.AlertConfigurationArgs{
			Enabled:   pulumi.Bool(true),
			EventType: pulumi.String("OUTSIDE_METRIC_THRESHOLD"),
			Matchers: mongodbatlas.AlertConfigurationMatcherArray{
				&mongodbatlas.AlertConfigurationMatcherArgs{
					FieldName: pulumi.String("HOSTNAME_AND_PORT"),
					Operator:  pulumi.String("EQUALS"),
					Value:     pulumi.String("SECONDARY"),
				},
			},
			MetricThresholdConfig: &mongodbatlas.AlertConfigurationMetricThresholdConfigArgs{
				MetricName: pulumi.String("ASSERT_REGULAR"),
				Mode:       pulumi.String("AVERAGE"),
				Operator:   pulumi.String("LESS_THAN"),
				Threshold:  pulumi.Float64(99),
				Units:      pulumi.String("RAW"),
			},
			Notifications: mongodbatlas.AlertConfigurationNotificationArray{
				&mongodbatlas.AlertConfigurationNotificationArgs{
					DelayMin:     pulumi.Int(0),
					EmailEnabled: pulumi.Bool(true),
					IntervalMin:  pulumi.Int(5),
					Roles: pulumi.StringArray{
						pulumi.String("GROUP_DATA_ACCESS_READ_ONLY"),
						pulumi.String("GROUP_CLUSTER_MANAGER"),
						pulumi.String("GROUP_DATA_ACCESS_ADMIN"),
					},
					SmsEnabled: pulumi.Bool(false),
					TypeName:   pulumi.String("GROUP"),
				},
				&mongodbatlas.AlertConfigurationNotificationArgs{
					DelayMin:     pulumi.Int(0),
					EmailEnabled: pulumi.Bool(false),
					IntervalMin:  pulumi.Int(5),
					SmsEnabled:   pulumi.Bool(true),
					TypeName:     pulumi.String("ORG"),
				},
			},
			ProjectId: pulumi.String("PROJECT ID"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.mongodbatlas.AlertConfiguration;
import com.pulumi.mongodbatlas.AlertConfigurationArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationMatcherArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationMetricThresholdConfigArgs;
import com.pulumi.mongodbatlas.inputs.AlertConfigurationNotificationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var test = new AlertConfiguration("test", AlertConfigurationArgs.builder()        
            .enabled(true)
            .eventType("OUTSIDE_METRIC_THRESHOLD")
            .matchers(AlertConfigurationMatcherArgs.builder()
                .fieldName("HOSTNAME_AND_PORT")
                .operator("EQUALS")
                .value("SECONDARY")
                .build())
            .metricThresholdConfig(AlertConfigurationMetricThresholdConfigArgs.builder()
                .metricName("ASSERT_REGULAR")
                .mode("AVERAGE")
                .operator("LESS_THAN")
                .threshold(99)
                .units("RAW")
                .build())
            .notifications(            
                AlertConfigurationNotificationArgs.builder()
                    .delayMin(0)
                    .emailEnabled(true)
                    .intervalMin(5)
                    .roles(                    
                        "GROUP_DATA_ACCESS_READ_ONLY",
                        "GROUP_CLUSTER_MANAGER",
                        "GROUP_DATA_ACCESS_ADMIN")
                    .smsEnabled(false)
                    .typeName("GROUP")
                    .build(),
                AlertConfigurationNotificationArgs.builder()
                    .delayMin(0)
                    .emailEnabled(false)
                    .intervalMin(5)
                    .smsEnabled(true)
                    .typeName("ORG")
                    .build())
            .projectId("PROJECT ID")
            .build());

    }
}
import pulumi
import pulumi_mongodbatlas as mongodbatlas

test = mongodbatlas.AlertConfiguration("test",
    enabled=True,
    event_type="OUTSIDE_METRIC_THRESHOLD",
    matchers=[mongodbatlas.AlertConfigurationMatcherArgs(
        field_name="HOSTNAME_AND_PORT",
        operator="EQUALS",
        value="SECONDARY",
    )],
    metric_threshold_config=mongodbatlas.AlertConfigurationMetricThresholdConfigArgs(
        metric_name="ASSERT_REGULAR",
        mode="AVERAGE",
        operator="LESS_THAN",
        threshold=99,
        units="RAW",
    ),
    notifications=[
        mongodbatlas.AlertConfigurationNotificationArgs(
            delay_min=0,
            email_enabled=True,
            interval_min=5,
            roles=[
                "GROUP_DATA_ACCESS_READ_ONLY",
                "GROUP_CLUSTER_MANAGER",
                "GROUP_DATA_ACCESS_ADMIN",
            ],
            sms_enabled=False,
            type_name="GROUP",
        ),
        mongodbatlas.AlertConfigurationNotificationArgs(
            delay_min=0,
            email_enabled=False,
            interval_min=5,
            sms_enabled=True,
            type_name="ORG",
        ),
    ],
    project_id="PROJECT ID")
import * as pulumi from "@pulumi/pulumi";
import * as mongodbatlas from "@pulumi/mongodbatlas";

const test = new mongodbatlas.AlertConfiguration("test", {
    enabled: true,
    eventType: "OUTSIDE_METRIC_THRESHOLD",
    matchers: [{
        fieldName: "HOSTNAME_AND_PORT",
        operator: "EQUALS",
        value: "SECONDARY",
    }],
    metricThresholdConfig: {
        metricName: "ASSERT_REGULAR",
        mode: "AVERAGE",
        operator: "LESS_THAN",
        threshold: 99,
        units: "RAW",
    },
    notifications: [
        {
            delayMin: 0,
            emailEnabled: true,
            intervalMin: 5,
            roles: [
                "GROUP_DATA_ACCESS_READ_ONLY",
                "GROUP_CLUSTER_MANAGER",
                "GROUP_DATA_ACCESS_ADMIN",
            ],
            smsEnabled: false,
            typeName: "GROUP",
        },
        {
            delayMin: 0,
            emailEnabled: false,
            intervalMin: 5,
            smsEnabled: true,
            typeName: "ORG",
        },
    ],
    projectId: "PROJECT ID",
});
resources:
  test:
    type: mongodbatlas:AlertConfiguration
    properties:
      enabled: true
      eventType: OUTSIDE_METRIC_THRESHOLD
      matchers:
        - fieldName: HOSTNAME_AND_PORT
          operator: EQUALS
          value: SECONDARY
      metricThresholdConfig:
        metricName: ASSERT_REGULAR
        mode: AVERAGE
        operator: LESS_THAN
        threshold: 99
        units: RAW
      notifications:
        - delayMin: 0
          emailEnabled: true
          intervalMin: 5
          roles:
            - GROUP_DATA_ACCESS_READ_ONLY
            - GROUP_CLUSTER_MANAGER
            - GROUP_DATA_ACCESS_ADMIN
          smsEnabled: false
          typeName: GROUP
        - delayMin: 0
          emailEnabled: false
          intervalMin: 5
          smsEnabled: true
          typeName: ORG
      projectId: PROJECT ID

Create AlertConfiguration Resource

new AlertConfiguration(name: string, args: AlertConfigurationArgs, opts?: CustomResourceOptions);
@overload
def AlertConfiguration(resource_name: str,
                       opts: Optional[ResourceOptions] = None,
                       enabled: Optional[bool] = None,
                       event_type: Optional[str] = None,
                       matchers: Optional[Sequence[AlertConfigurationMatcherArgs]] = None,
                       metric_threshold: Optional[Mapping[str, str]] = None,
                       metric_threshold_config: Optional[AlertConfigurationMetricThresholdConfigArgs] = None,
                       notifications: Optional[Sequence[AlertConfigurationNotificationArgs]] = None,
                       project_id: Optional[str] = None,
                       threshold: Optional[Mapping[str, str]] = None,
                       threshold_config: Optional[AlertConfigurationThresholdConfigArgs] = None)
@overload
def AlertConfiguration(resource_name: str,
                       args: AlertConfigurationArgs,
                       opts: Optional[ResourceOptions] = None)
func NewAlertConfiguration(ctx *Context, name string, args AlertConfigurationArgs, opts ...ResourceOption) (*AlertConfiguration, error)
public AlertConfiguration(string name, AlertConfigurationArgs args, CustomResourceOptions? opts = null)
public AlertConfiguration(String name, AlertConfigurationArgs args)
public AlertConfiguration(String name, AlertConfigurationArgs args, CustomResourceOptions options)
type: mongodbatlas:AlertConfiguration
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args AlertConfigurationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args AlertConfigurationArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args AlertConfigurationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args AlertConfigurationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args AlertConfigurationArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

AlertConfiguration Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The AlertConfiguration resource accepts the following input properties:

EventType string

The type of event that will trigger an alert.

Notifications List<AlertConfigurationNotificationArgs>
ProjectId string

The ID of the project where the alert configuration will create.

Enabled bool

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

Matchers List<AlertConfigurationMatcherArgs>
MetricThreshold Dictionary<string, string>

Deprecated:

use metric_threshold_config instead

MetricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
Threshold Dictionary<string, string>

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

ThresholdConfig AlertConfigurationThresholdConfigArgs
EventType string

The type of event that will trigger an alert.

Notifications []AlertConfigurationNotificationArgs
ProjectId string

The ID of the project where the alert configuration will create.

Enabled bool

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

Matchers []AlertConfigurationMatcherArgs
MetricThreshold map[string]string

Deprecated:

use metric_threshold_config instead

MetricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
Threshold map[string]string

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

ThresholdConfig AlertConfigurationThresholdConfigArgs
eventType String

The type of event that will trigger an alert.

notifications List<AlertConfigurationNotificationArgs>
projectId String

The ID of the project where the alert configuration will create.

enabled Boolean

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

matchers List<AlertConfigurationMatcherArgs>
metricThreshold Map<String,String>

Deprecated:

use metric_threshold_config instead

metricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
threshold Map<String,String>

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

thresholdConfig AlertConfigurationThresholdConfigArgs
eventType string

The type of event that will trigger an alert.

notifications AlertConfigurationNotificationArgs[]
projectId string

The ID of the project where the alert configuration will create.

enabled boolean

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

matchers AlertConfigurationMatcherArgs[]
metricThreshold {[key: string]: string}

Deprecated:

use metric_threshold_config instead

metricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
threshold {[key: string]: string}

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

thresholdConfig AlertConfigurationThresholdConfigArgs
event_type str

The type of event that will trigger an alert.

notifications Sequence[AlertConfigurationNotificationArgs]
project_id str

The ID of the project where the alert configuration will create.

enabled bool

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

matchers Sequence[AlertConfigurationMatcherArgs]
metric_threshold Mapping[str, str]

Deprecated:

use metric_threshold_config instead

metric_threshold_config AlertConfigurationMetricThresholdConfigArgs
threshold Mapping[str, str]

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

threshold_config AlertConfigurationThresholdConfigArgs
eventType String

The type of event that will trigger an alert.

notifications List<Property Map>
projectId String

The ID of the project where the alert configuration will create.

enabled Boolean

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

matchers List<Property Map>
metricThreshold Map<String>

Deprecated:

use metric_threshold_config instead

metricThresholdConfig Property Map
threshold Map<String>

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

thresholdConfig Property Map

Outputs

All input properties are implicitly available as output properties. Additionally, the AlertConfiguration resource produces the following output properties:

AlertConfigurationId string

Unique identifier for the alert configuration.

Created string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

Id string

The provider-assigned unique ID for this managed resource.

Updated string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

AlertConfigurationId string

Unique identifier for the alert configuration.

Created string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

Id string

The provider-assigned unique ID for this managed resource.

Updated string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alertConfigurationId String

Unique identifier for the alert configuration.

created String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

id String

The provider-assigned unique ID for this managed resource.

updated String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alertConfigurationId string

Unique identifier for the alert configuration.

created string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

id string

The provider-assigned unique ID for this managed resource.

updated string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alert_configuration_id str

Unique identifier for the alert configuration.

created str

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

id str

The provider-assigned unique ID for this managed resource.

updated str

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alertConfigurationId String

Unique identifier for the alert configuration.

created String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

id String

The provider-assigned unique ID for this managed resource.

updated String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

Look up Existing AlertConfiguration Resource

Get an existing AlertConfiguration resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: AlertConfigurationState, opts?: CustomResourceOptions): AlertConfiguration
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        alert_configuration_id: Optional[str] = None,
        created: Optional[str] = None,
        enabled: Optional[bool] = None,
        event_type: Optional[str] = None,
        matchers: Optional[Sequence[AlertConfigurationMatcherArgs]] = None,
        metric_threshold: Optional[Mapping[str, str]] = None,
        metric_threshold_config: Optional[AlertConfigurationMetricThresholdConfigArgs] = None,
        notifications: Optional[Sequence[AlertConfigurationNotificationArgs]] = None,
        project_id: Optional[str] = None,
        threshold: Optional[Mapping[str, str]] = None,
        threshold_config: Optional[AlertConfigurationThresholdConfigArgs] = None,
        updated: Optional[str] = None) -> AlertConfiguration
func GetAlertConfiguration(ctx *Context, name string, id IDInput, state *AlertConfigurationState, opts ...ResourceOption) (*AlertConfiguration, error)
public static AlertConfiguration Get(string name, Input<string> id, AlertConfigurationState? state, CustomResourceOptions? opts = null)
public static AlertConfiguration get(String name, Output<String> id, AlertConfigurationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
AlertConfigurationId string

Unique identifier for the alert configuration.

Created string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

Enabled bool

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

EventType string

The type of event that will trigger an alert.

Matchers List<AlertConfigurationMatcherArgs>
MetricThreshold Dictionary<string, string>

Deprecated:

use metric_threshold_config instead

MetricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
Notifications List<AlertConfigurationNotificationArgs>
ProjectId string

The ID of the project where the alert configuration will create.

Threshold Dictionary<string, string>

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

ThresholdConfig AlertConfigurationThresholdConfigArgs
Updated string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

AlertConfigurationId string

Unique identifier for the alert configuration.

Created string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

Enabled bool

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

EventType string

The type of event that will trigger an alert.

Matchers []AlertConfigurationMatcherArgs
MetricThreshold map[string]string

Deprecated:

use metric_threshold_config instead

MetricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
Notifications []AlertConfigurationNotificationArgs
ProjectId string

The ID of the project where the alert configuration will create.

Threshold map[string]string

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

ThresholdConfig AlertConfigurationThresholdConfigArgs
Updated string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alertConfigurationId String

Unique identifier for the alert configuration.

created String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

enabled Boolean

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

eventType String

The type of event that will trigger an alert.

matchers List<AlertConfigurationMatcherArgs>
metricThreshold Map<String,String>

Deprecated:

use metric_threshold_config instead

metricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
notifications List<AlertConfigurationNotificationArgs>
projectId String

The ID of the project where the alert configuration will create.

threshold Map<String,String>

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

thresholdConfig AlertConfigurationThresholdConfigArgs
updated String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alertConfigurationId string

Unique identifier for the alert configuration.

created string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

enabled boolean

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

eventType string

The type of event that will trigger an alert.

matchers AlertConfigurationMatcherArgs[]
metricThreshold {[key: string]: string}

Deprecated:

use metric_threshold_config instead

metricThresholdConfig AlertConfigurationMetricThresholdConfigArgs
notifications AlertConfigurationNotificationArgs[]
projectId string

The ID of the project where the alert configuration will create.

threshold {[key: string]: string}

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

thresholdConfig AlertConfigurationThresholdConfigArgs
updated string

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alert_configuration_id str

Unique identifier for the alert configuration.

created str

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

enabled bool

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

event_type str

The type of event that will trigger an alert.

matchers Sequence[AlertConfigurationMatcherArgs]
metric_threshold Mapping[str, str]

Deprecated:

use metric_threshold_config instead

metric_threshold_config AlertConfigurationMetricThresholdConfigArgs
notifications Sequence[AlertConfigurationNotificationArgs]
project_id str

The ID of the project where the alert configuration will create.

threshold Mapping[str, str]

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

threshold_config AlertConfigurationThresholdConfigArgs
updated str

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

alertConfigurationId String

Unique identifier for the alert configuration.

created String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was created.

enabled Boolean

It is not required, but If the attribute is omitted, by default will be false, and the configuration would be disabled. You must set true to enable the configuration.

eventType String

The type of event that will trigger an alert.

matchers List<Property Map>
metricThreshold Map<String>

Deprecated:

use metric_threshold_config instead

metricThresholdConfig Property Map
notifications List<Property Map>
projectId String

The ID of the project where the alert configuration will create.

threshold Map<String>

Threshold value outside of which an alert will be triggered.

Deprecated:

use threshold_config instead

thresholdConfig Property Map
updated String

Timestamp in ISO 8601 date and time format in UTC when this alert configuration was last updated.

Supporting Types

AlertConfigurationMatcher

FieldName string

Name of the field in the target object to match on.

Operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

Value string

If omitted, the configuration is disabled.

FieldName string

Name of the field in the target object to match on.

Operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

Value string

If omitted, the configuration is disabled.

fieldName String

Name of the field in the target object to match on.

operator String

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

value String

If omitted, the configuration is disabled.

fieldName string

Name of the field in the target object to match on.

operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

value string

If omitted, the configuration is disabled.

field_name str

Name of the field in the target object to match on.

operator str

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

value str

If omitted, the configuration is disabled.

fieldName String

Name of the field in the target object to match on.

operator String

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

value String

If omitted, the configuration is disabled.

AlertConfigurationMetricThresholdConfig

MetricName string

Name of the metric to check. The full list being quite large, please refer to atlas docs here for general metrics and here for serverless metrics

Mode string

This must be set to AVERAGE. Atlas computes the current metric value as an average.

Operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

Threshold double

Threshold value outside of which an alert will be triggered.

Units string

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

MetricName string

Name of the metric to check. The full list being quite large, please refer to atlas docs here for general metrics and here for serverless metrics

Mode string

This must be set to AVERAGE. Atlas computes the current metric value as an average.

Operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

Threshold float64

Threshold value outside of which an alert will be triggered.

Units string

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

metricName String

Name of the metric to check. The full list being quite large, please refer to atlas docs here for general metrics and here for serverless metrics

mode String

This must be set to AVERAGE. Atlas computes the current metric value as an average.

operator String

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold Double

Threshold value outside of which an alert will be triggered.

units String

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

metricName string

Name of the metric to check. The full list being quite large, please refer to atlas docs here for general metrics and here for serverless metrics

mode string

This must be set to AVERAGE. Atlas computes the current metric value as an average.

operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold number

Threshold value outside of which an alert will be triggered.

units string

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

metric_name str

Name of the metric to check. The full list being quite large, please refer to atlas docs here for general metrics and here for serverless metrics

mode str

This must be set to AVERAGE. Atlas computes the current metric value as an average.

operator str

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold float

Threshold value outside of which an alert will be triggered.

units str

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

metricName String

Name of the metric to check. The full list being quite large, please refer to atlas docs here for general metrics and here for serverless metrics

mode String

This must be set to AVERAGE. Atlas computes the current metric value as an average.

operator String

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold Number

Threshold value outside of which an alert will be triggered.

units String

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

AlertConfigurationNotification

ApiToken string

Slack API token. Required for the SLACK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

ChannelName string

Slack channel name. Required for the SLACK notifications type.

DatadogApiKey string

Datadog API Key. Found in the Datadog dashboard. Required for the DATADOG notifications type.

DatadogRegion string

Region that indicates which API URL to use. Accepted regions are: US, EU. The default Datadog region is US.

DelayMin int

Number of minutes to wait after an alert condition is detected before sending out the first notification.

EmailAddress string

Email address to which alert notifications are sent. Required for the EMAIL notifications type.

EmailEnabled bool

Flag indicating email notifications should be sent. This flag is only valid if type_name is set to ORG, GROUP, or USER.

FlowName string

Flowdock flow name in lower-case letters. Required for the FLOWDOCK notifications type

FlowdockApiToken string

The Flowdock personal API token. Required for the FLOWDOCK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

IntervalMin int

Number of minutes to wait between successive notifications for unacknowledged alerts that are not resolved. The minimum value is 5. NOTE PAGER_DUTY, VICTOR_OPS, and OPS_GENIE notifications do not return this value. The notification interval must be configured and managed within each external service.

MicrosoftTeamsWebhookUrl string

Microsoft Teams Webhook Uniform Resource Locator (URL) that MongoDB Cloud needs to send this notification via Microsoft Teams. Required if type_name is MICROSOFT_TEAMS. If the URL later becomes invalid, MongoDB Cloud sends an email to the project owners. If the key remains invalid, MongoDB Cloud removes it.

MobileNumber string

Mobile number to which alert notifications are sent. Required for the SMS notifications type.

OpsGenieApiKey string

Opsgenie API Key. Required for the OPS_GENIE notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

OpsGenieRegion string

Region that indicates which API URL to use. Accepted regions are: US ,EU. The default Opsgenie region is US.

OrgName string

Flowdock organization name in lower-case letters. This is the name that appears after www.flowdock.com/app/ in the URL string. Required for the FLOWDOCK notifications type.

Roles List<string>

Optional. One or more roles that receive the configured alert. If you include this field, Atlas sends alerts only to users assigned the roles you specify in the array. If you omit this field, Atlas sends alerts to users assigned any role. This parameter is only valid if type_name is set to ORG, GROUP, or USER. Accepted values are:

ServiceKey string

PagerDuty service key. Required for the PAGER_DUTY notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

SmsEnabled bool

Flag indicating if text message notifications should be sent to this user's mobile phone. This flag is only valid if type_name is set to ORG, GROUP, or USER.

TeamId string

Unique identifier of a team.

TeamName string

Label for the team that receives this notification.

TypeName string

Type of alert notification. Accepted values are:

Username string

Name of the Atlas user to which to send notifications. Only a user in the project that owns the alert configuration is allowed here. Required for the USER notifications type.

VictorOpsApiKey string

VictorOps API key. Required for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

VictorOpsRoutingKey string

VictorOps routing key. Optional for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

WebhookSecret string

Optional authentication secret for the WEBHOOK notifications type.

WebhookUrl string

Target URL for the WEBHOOK notifications type.

ApiToken string

Slack API token. Required for the SLACK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

ChannelName string

Slack channel name. Required for the SLACK notifications type.

DatadogApiKey string

Datadog API Key. Found in the Datadog dashboard. Required for the DATADOG notifications type.

DatadogRegion string

Region that indicates which API URL to use. Accepted regions are: US, EU. The default Datadog region is US.

DelayMin int

Number of minutes to wait after an alert condition is detected before sending out the first notification.

EmailAddress string

Email address to which alert notifications are sent. Required for the EMAIL notifications type.

EmailEnabled bool

Flag indicating email notifications should be sent. This flag is only valid if type_name is set to ORG, GROUP, or USER.

FlowName string

Flowdock flow name in lower-case letters. Required for the FLOWDOCK notifications type

FlowdockApiToken string

The Flowdock personal API token. Required for the FLOWDOCK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

IntervalMin int

Number of minutes to wait between successive notifications for unacknowledged alerts that are not resolved. The minimum value is 5. NOTE PAGER_DUTY, VICTOR_OPS, and OPS_GENIE notifications do not return this value. The notification interval must be configured and managed within each external service.

MicrosoftTeamsWebhookUrl string

Microsoft Teams Webhook Uniform Resource Locator (URL) that MongoDB Cloud needs to send this notification via Microsoft Teams. Required if type_name is MICROSOFT_TEAMS. If the URL later becomes invalid, MongoDB Cloud sends an email to the project owners. If the key remains invalid, MongoDB Cloud removes it.

MobileNumber string

Mobile number to which alert notifications are sent. Required for the SMS notifications type.

OpsGenieApiKey string

Opsgenie API Key. Required for the OPS_GENIE notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

OpsGenieRegion string

Region that indicates which API URL to use. Accepted regions are: US ,EU. The default Opsgenie region is US.

OrgName string

Flowdock organization name in lower-case letters. This is the name that appears after www.flowdock.com/app/ in the URL string. Required for the FLOWDOCK notifications type.

Roles []string

Optional. One or more roles that receive the configured alert. If you include this field, Atlas sends alerts only to users assigned the roles you specify in the array. If you omit this field, Atlas sends alerts to users assigned any role. This parameter is only valid if type_name is set to ORG, GROUP, or USER. Accepted values are:

ServiceKey string

PagerDuty service key. Required for the PAGER_DUTY notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

SmsEnabled bool

Flag indicating if text message notifications should be sent to this user's mobile phone. This flag is only valid if type_name is set to ORG, GROUP, or USER.

TeamId string

Unique identifier of a team.

TeamName string

Label for the team that receives this notification.

TypeName string

Type of alert notification. Accepted values are:

Username string

Name of the Atlas user to which to send notifications. Only a user in the project that owns the alert configuration is allowed here. Required for the USER notifications type.

VictorOpsApiKey string

VictorOps API key. Required for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

VictorOpsRoutingKey string

VictorOps routing key. Optional for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

WebhookSecret string

Optional authentication secret for the WEBHOOK notifications type.

WebhookUrl string

Target URL for the WEBHOOK notifications type.

apiToken String

Slack API token. Required for the SLACK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

channelName String

Slack channel name. Required for the SLACK notifications type.

datadogApiKey String

Datadog API Key. Found in the Datadog dashboard. Required for the DATADOG notifications type.

datadogRegion String

Region that indicates which API URL to use. Accepted regions are: US, EU. The default Datadog region is US.

delayMin Integer

Number of minutes to wait after an alert condition is detected before sending out the first notification.

emailAddress String

Email address to which alert notifications are sent. Required for the EMAIL notifications type.

emailEnabled Boolean

Flag indicating email notifications should be sent. This flag is only valid if type_name is set to ORG, GROUP, or USER.

flowName String

Flowdock flow name in lower-case letters. Required for the FLOWDOCK notifications type

flowdockApiToken String

The Flowdock personal API token. Required for the FLOWDOCK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

intervalMin Integer

Number of minutes to wait between successive notifications for unacknowledged alerts that are not resolved. The minimum value is 5. NOTE PAGER_DUTY, VICTOR_OPS, and OPS_GENIE notifications do not return this value. The notification interval must be configured and managed within each external service.

microsoftTeamsWebhookUrl String

Microsoft Teams Webhook Uniform Resource Locator (URL) that MongoDB Cloud needs to send this notification via Microsoft Teams. Required if type_name is MICROSOFT_TEAMS. If the URL later becomes invalid, MongoDB Cloud sends an email to the project owners. If the key remains invalid, MongoDB Cloud removes it.

mobileNumber String

Mobile number to which alert notifications are sent. Required for the SMS notifications type.

opsGenieApiKey String

Opsgenie API Key. Required for the OPS_GENIE notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

opsGenieRegion String

Region that indicates which API URL to use. Accepted regions are: US ,EU. The default Opsgenie region is US.

orgName String

Flowdock organization name in lower-case letters. This is the name that appears after www.flowdock.com/app/ in the URL string. Required for the FLOWDOCK notifications type.

roles List<String>

Optional. One or more roles that receive the configured alert. If you include this field, Atlas sends alerts only to users assigned the roles you specify in the array. If you omit this field, Atlas sends alerts to users assigned any role. This parameter is only valid if type_name is set to ORG, GROUP, or USER. Accepted values are:

serviceKey String

PagerDuty service key. Required for the PAGER_DUTY notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

smsEnabled Boolean

Flag indicating if text message notifications should be sent to this user's mobile phone. This flag is only valid if type_name is set to ORG, GROUP, or USER.

teamId String

Unique identifier of a team.

teamName String

Label for the team that receives this notification.

typeName String

Type of alert notification. Accepted values are:

username String

Name of the Atlas user to which to send notifications. Only a user in the project that owns the alert configuration is allowed here. Required for the USER notifications type.

victorOpsApiKey String

VictorOps API key. Required for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

victorOpsRoutingKey String

VictorOps routing key. Optional for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

webhookSecret String

Optional authentication secret for the WEBHOOK notifications type.

webhookUrl String

Target URL for the WEBHOOK notifications type.

apiToken string

Slack API token. Required for the SLACK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

channelName string

Slack channel name. Required for the SLACK notifications type.

datadogApiKey string

Datadog API Key. Found in the Datadog dashboard. Required for the DATADOG notifications type.

datadogRegion string

Region that indicates which API URL to use. Accepted regions are: US, EU. The default Datadog region is US.

delayMin number

Number of minutes to wait after an alert condition is detected before sending out the first notification.

emailAddress string

Email address to which alert notifications are sent. Required for the EMAIL notifications type.

emailEnabled boolean

Flag indicating email notifications should be sent. This flag is only valid if type_name is set to ORG, GROUP, or USER.

flowName string

Flowdock flow name in lower-case letters. Required for the FLOWDOCK notifications type

flowdockApiToken string

The Flowdock personal API token. Required for the FLOWDOCK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

intervalMin number

Number of minutes to wait between successive notifications for unacknowledged alerts that are not resolved. The minimum value is 5. NOTE PAGER_DUTY, VICTOR_OPS, and OPS_GENIE notifications do not return this value. The notification interval must be configured and managed within each external service.

microsoftTeamsWebhookUrl string

Microsoft Teams Webhook Uniform Resource Locator (URL) that MongoDB Cloud needs to send this notification via Microsoft Teams. Required if type_name is MICROSOFT_TEAMS. If the URL later becomes invalid, MongoDB Cloud sends an email to the project owners. If the key remains invalid, MongoDB Cloud removes it.

mobileNumber string

Mobile number to which alert notifications are sent. Required for the SMS notifications type.

opsGenieApiKey string

Opsgenie API Key. Required for the OPS_GENIE notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

opsGenieRegion string

Region that indicates which API URL to use. Accepted regions are: US ,EU. The default Opsgenie region is US.

orgName string

Flowdock organization name in lower-case letters. This is the name that appears after www.flowdock.com/app/ in the URL string. Required for the FLOWDOCK notifications type.

roles string[]

Optional. One or more roles that receive the configured alert. If you include this field, Atlas sends alerts only to users assigned the roles you specify in the array. If you omit this field, Atlas sends alerts to users assigned any role. This parameter is only valid if type_name is set to ORG, GROUP, or USER. Accepted values are:

serviceKey string

PagerDuty service key. Required for the PAGER_DUTY notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

smsEnabled boolean

Flag indicating if text message notifications should be sent to this user's mobile phone. This flag is only valid if type_name is set to ORG, GROUP, or USER.

teamId string

Unique identifier of a team.

teamName string

Label for the team that receives this notification.

typeName string

Type of alert notification. Accepted values are:

username string

Name of the Atlas user to which to send notifications. Only a user in the project that owns the alert configuration is allowed here. Required for the USER notifications type.

victorOpsApiKey string

VictorOps API key. Required for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

victorOpsRoutingKey string

VictorOps routing key. Optional for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

webhookSecret string

Optional authentication secret for the WEBHOOK notifications type.

webhookUrl string

Target URL for the WEBHOOK notifications type.

api_token str

Slack API token. Required for the SLACK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

channel_name str

Slack channel name. Required for the SLACK notifications type.

datadog_api_key str

Datadog API Key. Found in the Datadog dashboard. Required for the DATADOG notifications type.

datadog_region str

Region that indicates which API URL to use. Accepted regions are: US, EU. The default Datadog region is US.

delay_min int

Number of minutes to wait after an alert condition is detected before sending out the first notification.

email_address str

Email address to which alert notifications are sent. Required for the EMAIL notifications type.

email_enabled bool

Flag indicating email notifications should be sent. This flag is only valid if type_name is set to ORG, GROUP, or USER.

flow_name str

Flowdock flow name in lower-case letters. Required for the FLOWDOCK notifications type

flowdock_api_token str

The Flowdock personal API token. Required for the FLOWDOCK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

interval_min int

Number of minutes to wait between successive notifications for unacknowledged alerts that are not resolved. The minimum value is 5. NOTE PAGER_DUTY, VICTOR_OPS, and OPS_GENIE notifications do not return this value. The notification interval must be configured and managed within each external service.

microsoft_teams_webhook_url str

Microsoft Teams Webhook Uniform Resource Locator (URL) that MongoDB Cloud needs to send this notification via Microsoft Teams. Required if type_name is MICROSOFT_TEAMS. If the URL later becomes invalid, MongoDB Cloud sends an email to the project owners. If the key remains invalid, MongoDB Cloud removes it.

mobile_number str

Mobile number to which alert notifications are sent. Required for the SMS notifications type.

ops_genie_api_key str

Opsgenie API Key. Required for the OPS_GENIE notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

ops_genie_region str

Region that indicates which API URL to use. Accepted regions are: US ,EU. The default Opsgenie region is US.

org_name str

Flowdock organization name in lower-case letters. This is the name that appears after www.flowdock.com/app/ in the URL string. Required for the FLOWDOCK notifications type.

roles Sequence[str]

Optional. One or more roles that receive the configured alert. If you include this field, Atlas sends alerts only to users assigned the roles you specify in the array. If you omit this field, Atlas sends alerts to users assigned any role. This parameter is only valid if type_name is set to ORG, GROUP, or USER. Accepted values are:

service_key str

PagerDuty service key. Required for the PAGER_DUTY notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

sms_enabled bool

Flag indicating if text message notifications should be sent to this user's mobile phone. This flag is only valid if type_name is set to ORG, GROUP, or USER.

team_id str

Unique identifier of a team.

team_name str

Label for the team that receives this notification.

type_name str

Type of alert notification. Accepted values are:

username str

Name of the Atlas user to which to send notifications. Only a user in the project that owns the alert configuration is allowed here. Required for the USER notifications type.

victor_ops_api_key str

VictorOps API key. Required for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

victor_ops_routing_key str

VictorOps routing key. Optional for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

webhook_secret str

Optional authentication secret for the WEBHOOK notifications type.

webhook_url str

Target URL for the WEBHOOK notifications type.

apiToken String

Slack API token. Required for the SLACK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

channelName String

Slack channel name. Required for the SLACK notifications type.

datadogApiKey String

Datadog API Key. Found in the Datadog dashboard. Required for the DATADOG notifications type.

datadogRegion String

Region that indicates which API URL to use. Accepted regions are: US, EU. The default Datadog region is US.

delayMin Number

Number of minutes to wait after an alert condition is detected before sending out the first notification.

emailAddress String

Email address to which alert notifications are sent. Required for the EMAIL notifications type.

emailEnabled Boolean

Flag indicating email notifications should be sent. This flag is only valid if type_name is set to ORG, GROUP, or USER.

flowName String

Flowdock flow name in lower-case letters. Required for the FLOWDOCK notifications type

flowdockApiToken String

The Flowdock personal API token. Required for the FLOWDOCK notifications type. If the token later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

intervalMin Number

Number of minutes to wait between successive notifications for unacknowledged alerts that are not resolved. The minimum value is 5. NOTE PAGER_DUTY, VICTOR_OPS, and OPS_GENIE notifications do not return this value. The notification interval must be configured and managed within each external service.

microsoftTeamsWebhookUrl String

Microsoft Teams Webhook Uniform Resource Locator (URL) that MongoDB Cloud needs to send this notification via Microsoft Teams. Required if type_name is MICROSOFT_TEAMS. If the URL later becomes invalid, MongoDB Cloud sends an email to the project owners. If the key remains invalid, MongoDB Cloud removes it.

mobileNumber String

Mobile number to which alert notifications are sent. Required for the SMS notifications type.

opsGenieApiKey String

Opsgenie API Key. Required for the OPS_GENIE notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the token.

opsGenieRegion String

Region that indicates which API URL to use. Accepted regions are: US ,EU. The default Opsgenie region is US.

orgName String

Flowdock organization name in lower-case letters. This is the name that appears after www.flowdock.com/app/ in the URL string. Required for the FLOWDOCK notifications type.

roles List<String>

Optional. One or more roles that receive the configured alert. If you include this field, Atlas sends alerts only to users assigned the roles you specify in the array. If you omit this field, Atlas sends alerts to users assigned any role. This parameter is only valid if type_name is set to ORG, GROUP, or USER. Accepted values are:

serviceKey String

PagerDuty service key. Required for the PAGER_DUTY notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

smsEnabled Boolean

Flag indicating if text message notifications should be sent to this user's mobile phone. This flag is only valid if type_name is set to ORG, GROUP, or USER.

teamId String

Unique identifier of a team.

teamName String

Label for the team that receives this notification.

typeName String

Type of alert notification. Accepted values are:

username String

Name of the Atlas user to which to send notifications. Only a user in the project that owns the alert configuration is allowed here. Required for the USER notifications type.

victorOpsApiKey String

VictorOps API key. Required for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

victorOpsRoutingKey String

VictorOps routing key. Optional for the VICTOR_OPS notifications type. If the key later becomes invalid, Atlas sends an email to the project owner and eventually removes the key.

webhookSecret String

Optional authentication secret for the WEBHOOK notifications type.

webhookUrl String

Target URL for the WEBHOOK notifications type.

AlertConfigurationThresholdConfig

Operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

Threshold double

Threshold value outside of which an alert will be triggered.

Units string

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

Operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

Threshold float64

Threshold value outside of which an alert will be triggered.

Units string

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

operator String

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold Double

Threshold value outside of which an alert will be triggered.

units String

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

operator string

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold number

Threshold value outside of which an alert will be triggered.

units string

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

operator str

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold float

Threshold value outside of which an alert will be triggered.

units str

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

operator String

If omitted, the configuration is disabled. Accepted values are: Accepted values are: Accepted values are:

threshold Number

Threshold value outside of which an alert will be triggered.

units String

The units for the threshold value. Depends on the type of metric. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values. Refer to the MongoDB API Alert Configuration documentation for a list of accepted values.

Import

Alert Configuration can be imported using the project_id-alert_configuration_id, e.g.

 $ pulumi import mongodbatlas:index/alertConfiguration:AlertConfiguration test 5d0f1f74cf09a29120e123cd-5d0f1f74cf09a29120e1fscg

For more information seeMongoDB Atlas API Reference.

Package Details

Repository
MongoDB Atlas pulumi/pulumi-mongodbatlas
License
Apache-2.0
Notes

This Pulumi package is based on the mongodbatlas Terraform Provider.