1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. cms
  5. AlarmContactGroup
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.cms.AlarmContactGroup

Explore with Pulumi AI

Provides a CMS Alarm Contact Group resource.

For information about CMS Alarm Contact Group and how to use it, see What is Alarm Contact Group.

NOTE: Available since v1.101.0.

Example Usage

Basic Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const example = new alicloud.cms.AlarmContactGroup("example", {alarmContactGroupName: "tf-example"});
Copy
import pulumi
import pulumi_alicloud as alicloud

example = alicloud.cms.AlarmContactGroup("example", alarm_contact_group_name="tf-example")
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := cms.NewAlarmContactGroup(ctx, "example", &cms.AlarmContactGroupArgs{
			AlarmContactGroupName: pulumi.String("tf-example"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var example = new AliCloud.Cms.AlarmContactGroup("example", new()
    {
        AlarmContactGroupName = "tf-example",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.cms.AlarmContactGroup;
import com.pulumi.alicloud.cms.AlarmContactGroupArgs;
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 example = new AlarmContactGroup("example", AlarmContactGroupArgs.builder()
            .alarmContactGroupName("tf-example")
            .build());

    }
}
Copy
resources:
  example:
    type: alicloud:cms:AlarmContactGroup
    properties:
      alarmContactGroupName: tf-example
Copy

Create AlarmContactGroup Resource

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

Constructor syntax

new AlarmContactGroup(name: string, args: AlarmContactGroupArgs, opts?: CustomResourceOptions);
@overload
def AlarmContactGroup(resource_name: str,
                      args: AlarmContactGroupArgs,
                      opts: Optional[ResourceOptions] = None)

@overload
def AlarmContactGroup(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      alarm_contact_group_name: Optional[str] = None,
                      contacts: Optional[Sequence[str]] = None,
                      describe: Optional[str] = None,
                      enable_subscribed: Optional[bool] = None)
func NewAlarmContactGroup(ctx *Context, name string, args AlarmContactGroupArgs, opts ...ResourceOption) (*AlarmContactGroup, error)
public AlarmContactGroup(string name, AlarmContactGroupArgs args, CustomResourceOptions? opts = null)
public AlarmContactGroup(String name, AlarmContactGroupArgs args)
public AlarmContactGroup(String name, AlarmContactGroupArgs args, CustomResourceOptions options)
type: alicloud:cms:AlarmContactGroup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. AlarmContactGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. AlarmContactGroupArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. AlarmContactGroupArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. AlarmContactGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. AlarmContactGroupArgs
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 alarmContactGroupResource = new AliCloud.Cms.AlarmContactGroup("alarmContactGroupResource", new()
{
    AlarmContactGroupName = "string",
    Contacts = new[]
    {
        "string",
    },
    Describe = "string",
    EnableSubscribed = false,
});
Copy
example, err := cms.NewAlarmContactGroup(ctx, "alarmContactGroupResource", &cms.AlarmContactGroupArgs{
	AlarmContactGroupName: pulumi.String("string"),
	Contacts: pulumi.StringArray{
		pulumi.String("string"),
	},
	Describe:         pulumi.String("string"),
	EnableSubscribed: pulumi.Bool(false),
})
Copy
var alarmContactGroupResource = new AlarmContactGroup("alarmContactGroupResource", AlarmContactGroupArgs.builder()
    .alarmContactGroupName("string")
    .contacts("string")
    .describe("string")
    .enableSubscribed(false)
    .build());
Copy
alarm_contact_group_resource = alicloud.cms.AlarmContactGroup("alarmContactGroupResource",
    alarm_contact_group_name="string",
    contacts=["string"],
    describe="string",
    enable_subscribed=False)
Copy
const alarmContactGroupResource = new alicloud.cms.AlarmContactGroup("alarmContactGroupResource", {
    alarmContactGroupName: "string",
    contacts: ["string"],
    describe: "string",
    enableSubscribed: false,
});
Copy
type: alicloud:cms:AlarmContactGroup
properties:
    alarmContactGroupName: string
    contacts:
        - string
    describe: string
    enableSubscribed: false
Copy

AlarmContactGroup 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 AlarmContactGroup resource accepts the following input properties:

AlarmContactGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the alarm group.
Contacts List<string>
The name of the alert contact.
Describe string
The description of the alert group.
EnableSubscribed bool
Whether to open weekly subscription.
AlarmContactGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the alarm group.
Contacts []string
The name of the alert contact.
Describe string
The description of the alert group.
EnableSubscribed bool
Whether to open weekly subscription.
alarmContactGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the alarm group.
contacts List<String>
The name of the alert contact.
describe String
The description of the alert group.
enableSubscribed Boolean
Whether to open weekly subscription.
alarmContactGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the alarm group.
contacts string[]
The name of the alert contact.
describe string
The description of the alert group.
enableSubscribed boolean
Whether to open weekly subscription.
alarm_contact_group_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the alarm group.
contacts Sequence[str]
The name of the alert contact.
describe str
The description of the alert group.
enable_subscribed bool
Whether to open weekly subscription.
alarmContactGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the alarm group.
contacts List<String>
The name of the alert contact.
describe String
The description of the alert group.
enableSubscribed Boolean
Whether to open weekly subscription.

Outputs

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

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing AlarmContactGroup Resource

Get an existing AlarmContactGroup 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?: AlarmContactGroupState, opts?: CustomResourceOptions): AlarmContactGroup
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        alarm_contact_group_name: Optional[str] = None,
        contacts: Optional[Sequence[str]] = None,
        describe: Optional[str] = None,
        enable_subscribed: Optional[bool] = None) -> AlarmContactGroup
func GetAlarmContactGroup(ctx *Context, name string, id IDInput, state *AlarmContactGroupState, opts ...ResourceOption) (*AlarmContactGroup, error)
public static AlarmContactGroup Get(string name, Input<string> id, AlarmContactGroupState? state, CustomResourceOptions? opts = null)
public static AlarmContactGroup get(String name, Output<String> id, AlarmContactGroupState state, CustomResourceOptions options)
resources:  _:    type: alicloud:cms:AlarmContactGroup    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
AlarmContactGroupName Changes to this property will trigger replacement. string
The name of the alarm group.
Contacts List<string>
The name of the alert contact.
Describe string
The description of the alert group.
EnableSubscribed bool
Whether to open weekly subscription.
AlarmContactGroupName Changes to this property will trigger replacement. string
The name of the alarm group.
Contacts []string
The name of the alert contact.
Describe string
The description of the alert group.
EnableSubscribed bool
Whether to open weekly subscription.
alarmContactGroupName Changes to this property will trigger replacement. String
The name of the alarm group.
contacts List<String>
The name of the alert contact.
describe String
The description of the alert group.
enableSubscribed Boolean
Whether to open weekly subscription.
alarmContactGroupName Changes to this property will trigger replacement. string
The name of the alarm group.
contacts string[]
The name of the alert contact.
describe string
The description of the alert group.
enableSubscribed boolean
Whether to open weekly subscription.
alarm_contact_group_name Changes to this property will trigger replacement. str
The name of the alarm group.
contacts Sequence[str]
The name of the alert contact.
describe str
The description of the alert group.
enable_subscribed bool
Whether to open weekly subscription.
alarmContactGroupName Changes to this property will trigger replacement. String
The name of the alarm group.
contacts List<String>
The name of the alert contact.
describe String
The description of the alert group.
enableSubscribed Boolean
Whether to open weekly subscription.

Import

CMS Alarm Contact Group can be imported using the id, e.g.

$ pulumi import alicloud:cms/alarmContactGroup:AlarmContactGroup example tf-testacc123
Copy

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

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.