1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. StackMonitoring
  5. MonitoringTemplateAlarmCondition
Oracle Cloud Infrastructure v2.27.0 published on Thursday, Mar 20, 2025 by Pulumi

oci.StackMonitoring.MonitoringTemplateAlarmCondition

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.27.0 published on Thursday, Mar 20, 2025 by Pulumi

    This resource provides the Monitoring Template Alarm Condition resource in Oracle Cloud Infrastructure Stack Monitoring service.

    Create a new alarm condition in same monitoringTemplate compartment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testMonitoringTemplateAlarmCondition = new oci.stackmonitoring.MonitoringTemplateAlarmCondition("test_monitoring_template_alarm_condition", {
        conditionType: monitoringTemplateAlarmConditionConditionType,
        conditions: [{
            query: monitoringTemplateAlarmConditionConditionsQuery,
            severity: monitoringTemplateAlarmConditionConditionsSeverity,
            body: monitoringTemplateAlarmConditionConditionsBody,
            shouldAppendNote: monitoringTemplateAlarmConditionConditionsShouldAppendNote,
            shouldAppendUrl: monitoringTemplateAlarmConditionConditionsShouldAppendUrl,
            triggerDelay: monitoringTemplateAlarmConditionConditionsTriggerDelay,
        }],
        metricName: testMetric.name,
        monitoringTemplateId: testMonitoringTemplate.id,
        namespace: monitoringTemplateAlarmConditionNamespace,
        resourceType: monitoringTemplateAlarmConditionResourceType,
        compositeType: monitoringTemplateAlarmConditionCompositeType,
        definedTags: {
            "foo-namespace.bar-key": "value",
        },
        freeformTags: {
            "bar-key": "value",
        },
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_monitoring_template_alarm_condition = oci.stack_monitoring.MonitoringTemplateAlarmCondition("test_monitoring_template_alarm_condition",
        condition_type=monitoring_template_alarm_condition_condition_type,
        conditions=[{
            "query": monitoring_template_alarm_condition_conditions_query,
            "severity": monitoring_template_alarm_condition_conditions_severity,
            "body": monitoring_template_alarm_condition_conditions_body,
            "should_append_note": monitoring_template_alarm_condition_conditions_should_append_note,
            "should_append_url": monitoring_template_alarm_condition_conditions_should_append_url,
            "trigger_delay": monitoring_template_alarm_condition_conditions_trigger_delay,
        }],
        metric_name=test_metric["name"],
        monitoring_template_id=test_monitoring_template["id"],
        namespace=monitoring_template_alarm_condition_namespace,
        resource_type=monitoring_template_alarm_condition_resource_type,
        composite_type=monitoring_template_alarm_condition_composite_type,
        defined_tags={
            "foo-namespace.bar-key": "value",
        },
        freeform_tags={
            "bar-key": "value",
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/stackmonitoring"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := stackmonitoring.NewMonitoringTemplateAlarmCondition(ctx, "test_monitoring_template_alarm_condition", &stackmonitoring.MonitoringTemplateAlarmConditionArgs{
    			ConditionType: pulumi.Any(monitoringTemplateAlarmConditionConditionType),
    			Conditions: stackmonitoring.MonitoringTemplateAlarmConditionConditionArray{
    				&stackmonitoring.MonitoringTemplateAlarmConditionConditionArgs{
    					Query:            pulumi.Any(monitoringTemplateAlarmConditionConditionsQuery),
    					Severity:         pulumi.Any(monitoringTemplateAlarmConditionConditionsSeverity),
    					Body:             pulumi.Any(monitoringTemplateAlarmConditionConditionsBody),
    					ShouldAppendNote: pulumi.Any(monitoringTemplateAlarmConditionConditionsShouldAppendNote),
    					ShouldAppendUrl:  pulumi.Any(monitoringTemplateAlarmConditionConditionsShouldAppendUrl),
    					TriggerDelay:     pulumi.Any(monitoringTemplateAlarmConditionConditionsTriggerDelay),
    				},
    			},
    			MetricName:           pulumi.Any(testMetric.Name),
    			MonitoringTemplateId: pulumi.Any(testMonitoringTemplate.Id),
    			Namespace:            pulumi.Any(monitoringTemplateAlarmConditionNamespace),
    			ResourceType:         pulumi.Any(monitoringTemplateAlarmConditionResourceType),
    			CompositeType:        pulumi.Any(monitoringTemplateAlarmConditionCompositeType),
    			DefinedTags: pulumi.StringMap{
    				"foo-namespace.bar-key": pulumi.String("value"),
    			},
    			FreeformTags: pulumi.StringMap{
    				"bar-key": pulumi.String("value"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testMonitoringTemplateAlarmCondition = new Oci.StackMonitoring.MonitoringTemplateAlarmCondition("test_monitoring_template_alarm_condition", new()
        {
            ConditionType = monitoringTemplateAlarmConditionConditionType,
            Conditions = new[]
            {
                new Oci.StackMonitoring.Inputs.MonitoringTemplateAlarmConditionConditionArgs
                {
                    Query = monitoringTemplateAlarmConditionConditionsQuery,
                    Severity = monitoringTemplateAlarmConditionConditionsSeverity,
                    Body = monitoringTemplateAlarmConditionConditionsBody,
                    ShouldAppendNote = monitoringTemplateAlarmConditionConditionsShouldAppendNote,
                    ShouldAppendUrl = monitoringTemplateAlarmConditionConditionsShouldAppendUrl,
                    TriggerDelay = monitoringTemplateAlarmConditionConditionsTriggerDelay,
                },
            },
            MetricName = testMetric.Name,
            MonitoringTemplateId = testMonitoringTemplate.Id,
            Namespace = monitoringTemplateAlarmConditionNamespace,
            ResourceType = monitoringTemplateAlarmConditionResourceType,
            CompositeType = monitoringTemplateAlarmConditionCompositeType,
            DefinedTags = 
            {
                { "foo-namespace.bar-key", "value" },
            },
            FreeformTags = 
            {
                { "bar-key", "value" },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.StackMonitoring.MonitoringTemplateAlarmCondition;
    import com.pulumi.oci.StackMonitoring.MonitoringTemplateAlarmConditionArgs;
    import com.pulumi.oci.StackMonitoring.inputs.MonitoringTemplateAlarmConditionConditionArgs;
    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 testMonitoringTemplateAlarmCondition = new MonitoringTemplateAlarmCondition("testMonitoringTemplateAlarmCondition", MonitoringTemplateAlarmConditionArgs.builder()
                .conditionType(monitoringTemplateAlarmConditionConditionType)
                .conditions(MonitoringTemplateAlarmConditionConditionArgs.builder()
                    .query(monitoringTemplateAlarmConditionConditionsQuery)
                    .severity(monitoringTemplateAlarmConditionConditionsSeverity)
                    .body(monitoringTemplateAlarmConditionConditionsBody)
                    .shouldAppendNote(monitoringTemplateAlarmConditionConditionsShouldAppendNote)
                    .shouldAppendUrl(monitoringTemplateAlarmConditionConditionsShouldAppendUrl)
                    .triggerDelay(monitoringTemplateAlarmConditionConditionsTriggerDelay)
                    .build())
                .metricName(testMetric.name())
                .monitoringTemplateId(testMonitoringTemplate.id())
                .namespace(monitoringTemplateAlarmConditionNamespace)
                .resourceType(monitoringTemplateAlarmConditionResourceType)
                .compositeType(monitoringTemplateAlarmConditionCompositeType)
                .definedTags(Map.of("foo-namespace.bar-key", "value"))
                .freeformTags(Map.of("bar-key", "value"))
                .build());
    
        }
    }
    
    resources:
      testMonitoringTemplateAlarmCondition:
        type: oci:StackMonitoring:MonitoringTemplateAlarmCondition
        name: test_monitoring_template_alarm_condition
        properties:
          conditionType: ${monitoringTemplateAlarmConditionConditionType}
          conditions:
            - query: ${monitoringTemplateAlarmConditionConditionsQuery}
              severity: ${monitoringTemplateAlarmConditionConditionsSeverity}
              body: ${monitoringTemplateAlarmConditionConditionsBody}
              shouldAppendNote: ${monitoringTemplateAlarmConditionConditionsShouldAppendNote}
              shouldAppendUrl: ${monitoringTemplateAlarmConditionConditionsShouldAppendUrl}
              triggerDelay: ${monitoringTemplateAlarmConditionConditionsTriggerDelay}
          metricName: ${testMetric.name}
          monitoringTemplateId: ${testMonitoringTemplate.id}
          namespace: ${monitoringTemplateAlarmConditionNamespace}
          resourceType: ${monitoringTemplateAlarmConditionResourceType}
          compositeType: ${monitoringTemplateAlarmConditionCompositeType}
          definedTags:
            foo-namespace.bar-key: value
          freeformTags:
            bar-key: value
    

    Create MonitoringTemplateAlarmCondition Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new MonitoringTemplateAlarmCondition(name: string, args: MonitoringTemplateAlarmConditionArgs, opts?: CustomResourceOptions);
    @overload
    def MonitoringTemplateAlarmCondition(resource_name: str,
                                         args: MonitoringTemplateAlarmConditionArgs,
                                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def MonitoringTemplateAlarmCondition(resource_name: str,
                                         opts: Optional[ResourceOptions] = None,
                                         condition_type: Optional[str] = None,
                                         conditions: Optional[Sequence[_stackmonitoring.MonitoringTemplateAlarmConditionConditionArgs]] = None,
                                         metric_name: Optional[str] = None,
                                         monitoring_template_id: Optional[str] = None,
                                         namespace: Optional[str] = None,
                                         resource_type: Optional[str] = None,
                                         composite_type: Optional[str] = None,
                                         defined_tags: Optional[Mapping[str, str]] = None,
                                         freeform_tags: Optional[Mapping[str, str]] = None)
    func NewMonitoringTemplateAlarmCondition(ctx *Context, name string, args MonitoringTemplateAlarmConditionArgs, opts ...ResourceOption) (*MonitoringTemplateAlarmCondition, error)
    public MonitoringTemplateAlarmCondition(string name, MonitoringTemplateAlarmConditionArgs args, CustomResourceOptions? opts = null)
    public MonitoringTemplateAlarmCondition(String name, MonitoringTemplateAlarmConditionArgs args)
    public MonitoringTemplateAlarmCondition(String name, MonitoringTemplateAlarmConditionArgs args, CustomResourceOptions options)
    
    type: oci:StackMonitoring:MonitoringTemplateAlarmCondition
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args MonitoringTemplateAlarmConditionArgs
    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 MonitoringTemplateAlarmConditionArgs
    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 MonitoringTemplateAlarmConditionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args MonitoringTemplateAlarmConditionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args MonitoringTemplateAlarmConditionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var monitoringTemplateAlarmConditionResource = new Oci.StackMonitoring.MonitoringTemplateAlarmCondition("monitoringTemplateAlarmConditionResource", new()
    {
        ConditionType = "string",
        Conditions = new[]
        {
            new Oci.StackMonitoring.Inputs.MonitoringTemplateAlarmConditionConditionArgs
            {
                Query = "string",
                Severity = "string",
                Body = "string",
                ShouldAppendNote = false,
                ShouldAppendUrl = false,
                TriggerDelay = "string",
            },
        },
        MetricName = "string",
        MonitoringTemplateId = "string",
        Namespace = "string",
        ResourceType = "string",
        CompositeType = "string",
        DefinedTags = 
        {
            { "string", "string" },
        },
        FreeformTags = 
        {
            { "string", "string" },
        },
    });
    
    example, err := StackMonitoring.NewMonitoringTemplateAlarmCondition(ctx, "monitoringTemplateAlarmConditionResource", &StackMonitoring.MonitoringTemplateAlarmConditionArgs{
    	ConditionType: pulumi.String("string"),
    	Conditions: stackmonitoring.MonitoringTemplateAlarmConditionConditionArray{
    		&stackmonitoring.MonitoringTemplateAlarmConditionConditionArgs{
    			Query:            pulumi.String("string"),
    			Severity:         pulumi.String("string"),
    			Body:             pulumi.String("string"),
    			ShouldAppendNote: pulumi.Bool(false),
    			ShouldAppendUrl:  pulumi.Bool(false),
    			TriggerDelay:     pulumi.String("string"),
    		},
    	},
    	MetricName:           pulumi.String("string"),
    	MonitoringTemplateId: pulumi.String("string"),
    	Namespace:            pulumi.String("string"),
    	ResourceType:         pulumi.String("string"),
    	CompositeType:        pulumi.String("string"),
    	DefinedTags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	FreeformTags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    })
    
    var monitoringTemplateAlarmConditionResource = new MonitoringTemplateAlarmCondition("monitoringTemplateAlarmConditionResource", MonitoringTemplateAlarmConditionArgs.builder()
        .conditionType("string")
        .conditions(MonitoringTemplateAlarmConditionConditionArgs.builder()
            .query("string")
            .severity("string")
            .body("string")
            .shouldAppendNote(false)
            .shouldAppendUrl(false)
            .triggerDelay("string")
            .build())
        .metricName("string")
        .monitoringTemplateId("string")
        .namespace("string")
        .resourceType("string")
        .compositeType("string")
        .definedTags(Map.of("string", "string"))
        .freeformTags(Map.of("string", "string"))
        .build());
    
    monitoring_template_alarm_condition_resource = oci.stack_monitoring.MonitoringTemplateAlarmCondition("monitoringTemplateAlarmConditionResource",
        condition_type="string",
        conditions=[{
            "query": "string",
            "severity": "string",
            "body": "string",
            "should_append_note": False,
            "should_append_url": False,
            "trigger_delay": "string",
        }],
        metric_name="string",
        monitoring_template_id="string",
        namespace="string",
        resource_type="string",
        composite_type="string",
        defined_tags={
            "string": "string",
        },
        freeform_tags={
            "string": "string",
        })
    
    const monitoringTemplateAlarmConditionResource = new oci.stackmonitoring.MonitoringTemplateAlarmCondition("monitoringTemplateAlarmConditionResource", {
        conditionType: "string",
        conditions: [{
            query: "string",
            severity: "string",
            body: "string",
            shouldAppendNote: false,
            shouldAppendUrl: false,
            triggerDelay: "string",
        }],
        metricName: "string",
        monitoringTemplateId: "string",
        namespace: "string",
        resourceType: "string",
        compositeType: "string",
        definedTags: {
            string: "string",
        },
        freeformTags: {
            string: "string",
        },
    });
    
    type: oci:StackMonitoring:MonitoringTemplateAlarmCondition
    properties:
        compositeType: string
        conditionType: string
        conditions:
            - body: string
              query: string
              severity: string
              shouldAppendNote: false
              shouldAppendUrl: false
              triggerDelay: string
        definedTags:
            string: string
        freeformTags:
            string: string
        metricName: string
        monitoringTemplateId: string
        namespace: string
        resourceType: string
    

    MonitoringTemplateAlarmCondition Resource Properties

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

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The MonitoringTemplateAlarmCondition resource accepts the following input properties:

    ConditionType string
    (Updatable) Type of defined monitoring template.
    Conditions List<MonitoringTemplateAlarmConditionCondition>
    (Updatable) Monitoring template conditions.
    MetricName string
    (Updatable) The metric name.
    MonitoringTemplateId string
    The OCID of the monitoring template.
    Namespace string
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    ResourceType string

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    CompositeType string
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    DefinedTags Dictionary<string, string>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    FreeformTags Dictionary<string, string>
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    ConditionType string
    (Updatable) Type of defined monitoring template.
    Conditions []MonitoringTemplateAlarmConditionConditionArgs
    (Updatable) Monitoring template conditions.
    MetricName string
    (Updatable) The metric name.
    MonitoringTemplateId string
    The OCID of the monitoring template.
    Namespace string
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    ResourceType string

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    CompositeType string
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    DefinedTags map[string]string
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    FreeformTags map[string]string
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    conditionType String
    (Updatable) Type of defined monitoring template.
    conditions List<MonitoringTemplateAlarmConditionCondition>
    (Updatable) Monitoring template conditions.
    metricName String
    (Updatable) The metric name.
    monitoringTemplateId String
    The OCID of the monitoring template.
    namespace String
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resourceType String

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compositeType String
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    definedTags Map<String,String>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeformTags Map<String,String>
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    conditionType string
    (Updatable) Type of defined monitoring template.
    conditions MonitoringTemplateAlarmConditionCondition[]
    (Updatable) Monitoring template conditions.
    metricName string
    (Updatable) The metric name.
    monitoringTemplateId string
    The OCID of the monitoring template.
    namespace string
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resourceType string

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compositeType string
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    definedTags {[key: string]: string}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeformTags {[key: string]: string}
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    condition_type str
    (Updatable) Type of defined monitoring template.
    conditions Sequence[stackmonitoring.MonitoringTemplateAlarmConditionConditionArgs]
    (Updatable) Monitoring template conditions.
    metric_name str
    (Updatable) The metric name.
    monitoring_template_id str
    The OCID of the monitoring template.
    namespace str
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resource_type str

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    composite_type str
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    defined_tags Mapping[str, str]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeform_tags Mapping[str, str]
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    conditionType String
    (Updatable) Type of defined monitoring template.
    conditions List<Property Map>
    (Updatable) Monitoring template conditions.
    metricName String
    (Updatable) The metric name.
    monitoringTemplateId String
    The OCID of the monitoring template.
    namespace String
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resourceType String

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compositeType String
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    definedTags Map<String>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeformTags Map<String>
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    The current lifecycle state of the monitoring template
    Status string
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    SystemTags Dictionary<string, string>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The date and time the alarm condition was created. Format defined by RFC3339.
    TimeUpdated string
    The date and time the alarm condition was updated. Format defined by RFC3339.
    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    The current lifecycle state of the monitoring template
    Status string
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    SystemTags map[string]string
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The date and time the alarm condition was created. Format defined by RFC3339.
    TimeUpdated string
    The date and time the alarm condition was updated. Format defined by RFC3339.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    The current lifecycle state of the monitoring template
    status String
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    systemTags Map<String,String>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The date and time the alarm condition was created. Format defined by RFC3339.
    timeUpdated String
    The date and time the alarm condition was updated. Format defined by RFC3339.
    id string
    The provider-assigned unique ID for this managed resource.
    state string
    The current lifecycle state of the monitoring template
    status string
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    systemTags {[key: string]: string}
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated string
    The date and time the alarm condition was created. Format defined by RFC3339.
    timeUpdated string
    The date and time the alarm condition was updated. Format defined by RFC3339.
    id str
    The provider-assigned unique ID for this managed resource.
    state str
    The current lifecycle state of the monitoring template
    status str
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    system_tags Mapping[str, str]
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    time_created str
    The date and time the alarm condition was created. Format defined by RFC3339.
    time_updated str
    The date and time the alarm condition was updated. Format defined by RFC3339.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    The current lifecycle state of the monitoring template
    status String
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    systemTags Map<String>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The date and time the alarm condition was created. Format defined by RFC3339.
    timeUpdated String
    The date and time the alarm condition was updated. Format defined by RFC3339.

    Look up Existing MonitoringTemplateAlarmCondition Resource

    Get an existing MonitoringTemplateAlarmCondition 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?: MonitoringTemplateAlarmConditionState, opts?: CustomResourceOptions): MonitoringTemplateAlarmCondition
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            composite_type: Optional[str] = None,
            condition_type: Optional[str] = None,
            conditions: Optional[Sequence[_stackmonitoring.MonitoringTemplateAlarmConditionConditionArgs]] = None,
            defined_tags: Optional[Mapping[str, str]] = None,
            freeform_tags: Optional[Mapping[str, str]] = None,
            metric_name: Optional[str] = None,
            monitoring_template_id: Optional[str] = None,
            namespace: Optional[str] = None,
            resource_type: Optional[str] = None,
            state: Optional[str] = None,
            status: Optional[str] = None,
            system_tags: Optional[Mapping[str, str]] = None,
            time_created: Optional[str] = None,
            time_updated: Optional[str] = None) -> MonitoringTemplateAlarmCondition
    func GetMonitoringTemplateAlarmCondition(ctx *Context, name string, id IDInput, state *MonitoringTemplateAlarmConditionState, opts ...ResourceOption) (*MonitoringTemplateAlarmCondition, error)
    public static MonitoringTemplateAlarmCondition Get(string name, Input<string> id, MonitoringTemplateAlarmConditionState? state, CustomResourceOptions? opts = null)
    public static MonitoringTemplateAlarmCondition get(String name, Output<String> id, MonitoringTemplateAlarmConditionState state, CustomResourceOptions options)
    resources:  _:    type: oci:StackMonitoring:MonitoringTemplateAlarmCondition    get:      id: ${id}
    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:
    CompositeType string
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    ConditionType string
    (Updatable) Type of defined monitoring template.
    Conditions List<MonitoringTemplateAlarmConditionCondition>
    (Updatable) Monitoring template conditions.
    DefinedTags Dictionary<string, string>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    FreeformTags Dictionary<string, string>
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    MetricName string
    (Updatable) The metric name.
    MonitoringTemplateId string
    The OCID of the monitoring template.
    Namespace string
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    ResourceType string

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    State string
    The current lifecycle state of the monitoring template
    Status string
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    SystemTags Dictionary<string, string>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The date and time the alarm condition was created. Format defined by RFC3339.
    TimeUpdated string
    The date and time the alarm condition was updated. Format defined by RFC3339.
    CompositeType string
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    ConditionType string
    (Updatable) Type of defined monitoring template.
    Conditions []MonitoringTemplateAlarmConditionConditionArgs
    (Updatable) Monitoring template conditions.
    DefinedTags map[string]string
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    FreeformTags map[string]string
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    MetricName string
    (Updatable) The metric name.
    MonitoringTemplateId string
    The OCID of the monitoring template.
    Namespace string
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    ResourceType string

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    State string
    The current lifecycle state of the monitoring template
    Status string
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    SystemTags map[string]string
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The date and time the alarm condition was created. Format defined by RFC3339.
    TimeUpdated string
    The date and time the alarm condition was updated. Format defined by RFC3339.
    compositeType String
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    conditionType String
    (Updatable) Type of defined monitoring template.
    conditions List<MonitoringTemplateAlarmConditionCondition>
    (Updatable) Monitoring template conditions.
    definedTags Map<String,String>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeformTags Map<String,String>
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    metricName String
    (Updatable) The metric name.
    monitoringTemplateId String
    The OCID of the monitoring template.
    namespace String
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resourceType String

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state String
    The current lifecycle state of the monitoring template
    status String
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    systemTags Map<String,String>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The date and time the alarm condition was created. Format defined by RFC3339.
    timeUpdated String
    The date and time the alarm condition was updated. Format defined by RFC3339.
    compositeType string
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    conditionType string
    (Updatable) Type of defined monitoring template.
    conditions MonitoringTemplateAlarmConditionCondition[]
    (Updatable) Monitoring template conditions.
    definedTags {[key: string]: string}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeformTags {[key: string]: string}
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    metricName string
    (Updatable) The metric name.
    monitoringTemplateId string
    The OCID of the monitoring template.
    namespace string
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resourceType string

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state string
    The current lifecycle state of the monitoring template
    status string
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    systemTags {[key: string]: string}
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated string
    The date and time the alarm condition was created. Format defined by RFC3339.
    timeUpdated string
    The date and time the alarm condition was updated. Format defined by RFC3339.
    composite_type str
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    condition_type str
    (Updatable) Type of defined monitoring template.
    conditions Sequence[stackmonitoring.MonitoringTemplateAlarmConditionConditionArgs]
    (Updatable) Monitoring template conditions.
    defined_tags Mapping[str, str]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeform_tags Mapping[str, str]
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    metric_name str
    (Updatable) The metric name.
    monitoring_template_id str
    The OCID of the monitoring template.
    namespace str
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resource_type str

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state str
    The current lifecycle state of the monitoring template
    status str
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    system_tags Mapping[str, str]
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    time_created str
    The date and time the alarm condition was created. Format defined by RFC3339.
    time_updated str
    The date and time the alarm condition was updated. Format defined by RFC3339.
    compositeType String
    (Updatable) The OCID of the composite resource type like EBS/PEOPLE_SOFT.
    conditionType String
    (Updatable) Type of defined monitoring template.
    conditions List<Property Map>
    (Updatable) Monitoring template conditions.
    definedTags Map<String>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    freeformTags Map<String>
    (Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    metricName String
    (Updatable) The metric name.
    monitoringTemplateId String
    The OCID of the monitoring template.
    namespace String
    (Updatable) The stack monitoring service or application emitting the metric that is evaluated by the alarm.
    resourceType String

    (Updatable) The resource group OCID.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state String
    The current lifecycle state of the monitoring template
    status String
    The current status of the monitoring template i.e. whether it is Published or Unpublished
    systemTags Map<String>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The date and time the alarm condition was created. Format defined by RFC3339.
    timeUpdated String
    The date and time the alarm condition was updated. Format defined by RFC3339.

    Supporting Types

    MonitoringTemplateAlarmConditionCondition, MonitoringTemplateAlarmConditionConditionArgs

    Query string
    (Updatable) The Monitoring Query Language (MQL) expression to evaluate for the alarm.
    Severity string
    (Updatable) Severity - Critical/Warning
    Body string
    (Updatable) The human-readable content of the delivered alarm notification. Oracle recommends providing guidance to operators for resolving the alarm condition. Consider adding links to standard runbook practices. Avoid entering confidential information.
    ShouldAppendNote bool
    (Updatable) Whether the note need to add into bottom of the body for mapping the alarms information with template or not.
    ShouldAppendUrl bool
    (Updatable) Whether the URL need to add into bottom of the body for mapping the alarms information with template or not.
    TriggerDelay string
    (Updatable) The period of time that the condition defined in the alarm must persist before the alarm state changes from "OK" to "FIRING".
    Query string
    (Updatable) The Monitoring Query Language (MQL) expression to evaluate for the alarm.
    Severity string
    (Updatable) Severity - Critical/Warning
    Body string
    (Updatable) The human-readable content of the delivered alarm notification. Oracle recommends providing guidance to operators for resolving the alarm condition. Consider adding links to standard runbook practices. Avoid entering confidential information.
    ShouldAppendNote bool
    (Updatable) Whether the note need to add into bottom of the body for mapping the alarms information with template or not.
    ShouldAppendUrl bool
    (Updatable) Whether the URL need to add into bottom of the body for mapping the alarms information with template or not.
    TriggerDelay string
    (Updatable) The period of time that the condition defined in the alarm must persist before the alarm state changes from "OK" to "FIRING".
    query String
    (Updatable) The Monitoring Query Language (MQL) expression to evaluate for the alarm.
    severity String
    (Updatable) Severity - Critical/Warning
    body String
    (Updatable) The human-readable content of the delivered alarm notification. Oracle recommends providing guidance to operators for resolving the alarm condition. Consider adding links to standard runbook practices. Avoid entering confidential information.
    shouldAppendNote Boolean
    (Updatable) Whether the note need to add into bottom of the body for mapping the alarms information with template or not.
    shouldAppendUrl Boolean
    (Updatable) Whether the URL need to add into bottom of the body for mapping the alarms information with template or not.
    triggerDelay String
    (Updatable) The period of time that the condition defined in the alarm must persist before the alarm state changes from "OK" to "FIRING".
    query string
    (Updatable) The Monitoring Query Language (MQL) expression to evaluate for the alarm.
    severity string
    (Updatable) Severity - Critical/Warning
    body string
    (Updatable) The human-readable content of the delivered alarm notification. Oracle recommends providing guidance to operators for resolving the alarm condition. Consider adding links to standard runbook practices. Avoid entering confidential information.
    shouldAppendNote boolean
    (Updatable) Whether the note need to add into bottom of the body for mapping the alarms information with template or not.
    shouldAppendUrl boolean
    (Updatable) Whether the URL need to add into bottom of the body for mapping the alarms information with template or not.
    triggerDelay string
    (Updatable) The period of time that the condition defined in the alarm must persist before the alarm state changes from "OK" to "FIRING".
    query str
    (Updatable) The Monitoring Query Language (MQL) expression to evaluate for the alarm.
    severity str
    (Updatable) Severity - Critical/Warning
    body str
    (Updatable) The human-readable content of the delivered alarm notification. Oracle recommends providing guidance to operators for resolving the alarm condition. Consider adding links to standard runbook practices. Avoid entering confidential information.
    should_append_note bool
    (Updatable) Whether the note need to add into bottom of the body for mapping the alarms information with template or not.
    should_append_url bool
    (Updatable) Whether the URL need to add into bottom of the body for mapping the alarms information with template or not.
    trigger_delay str
    (Updatable) The period of time that the condition defined in the alarm must persist before the alarm state changes from "OK" to "FIRING".
    query String
    (Updatable) The Monitoring Query Language (MQL) expression to evaluate for the alarm.
    severity String
    (Updatable) Severity - Critical/Warning
    body String
    (Updatable) The human-readable content of the delivered alarm notification. Oracle recommends providing guidance to operators for resolving the alarm condition. Consider adding links to standard runbook practices. Avoid entering confidential information.
    shouldAppendNote Boolean
    (Updatable) Whether the note need to add into bottom of the body for mapping the alarms information with template or not.
    shouldAppendUrl Boolean
    (Updatable) Whether the URL need to add into bottom of the body for mapping the alarms information with template or not.
    triggerDelay String
    (Updatable) The period of time that the condition defined in the alarm must persist before the alarm state changes from "OK" to "FIRING".

    Import

    MonitoringTemplateAlarmConditions can be imported using the id, e.g.

    $ pulumi import oci:StackMonitoring/monitoringTemplateAlarmCondition:MonitoringTemplateAlarmCondition test_monitoring_template_alarm_condition "monitoringTemplates/{monitoringTemplateId}/alarmConditions/{alarmConditionId}"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v2.27.0 published on Thursday, Mar 20, 2025 by Pulumi