Alarm Contact
Creates or modifies an alarm contact. For information about alarm contact and how to use it, see What is alarm contact.
NOTE: Available since v1.99.0.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
// You need to activate the link before you can return to the alarm contact information, otherwise diff will appear in terraform. So please confirm the activation link as soon as possible. Besides, you can ignore the diff of the alarm contact information by `lifestyle`.
const example = new alicloud.cms.AlarmContact("example", {
alarmContactName: "tf-example",
describe: "For example",
channelsMail: "terraform@test.com",
});
import pulumi
import pulumi_alicloud as alicloud
# You need to activate the link before you can return to the alarm contact information, otherwise diff will appear in terraform. So please confirm the activation link as soon as possible. Besides, you can ignore the diff of the alarm contact information by `lifestyle`.
example = alicloud.cms.AlarmContact("example",
alarm_contact_name="tf-example",
describe="For example",
channels_mail="terraform@test.com")
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
// You need to activate the link before you can return to the alarm contact information, otherwise diff will appear in terraform. So please confirm the activation link as soon as possible. Besides, you can ignore the diff of the alarm contact information by `lifestyle`.
var example = new AliCloud.Cms.AlarmContact("example", new()
{
AlarmContactName = "tf-example",
Describe = "For example",
ChannelsMail = "terraform@test.com",
});
});
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 {
// You need to activate the link before you can return to the alarm contact information, otherwise diff will appear in terraform. So please confirm the activation link as soon as possible. Besides, you can ignore the diff of the alarm contact information by `lifestyle`.
_, err := cms.NewAlarmContact(ctx, "example", &cms.AlarmContactArgs{
AlarmContactName: pulumi.String("tf-example"),
Describe: pulumi.String("For example"),
ChannelsMail: pulumi.String("terraform@test.com"),
})
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.alicloud.cms.AlarmContact;
import com.pulumi.alicloud.cms.AlarmContactArgs;
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) {
// You need to activate the link before you can return to the alarm contact information, otherwise diff will appear in terraform. So please confirm the activation link as soon as possible. Besides, you can ignore the diff of the alarm contact information by `lifestyle`.
var example = new AlarmContact("example", AlarmContactArgs.builder()
.alarmContactName("tf-example")
.describe("For example")
.channelsMail("terraform@test.com")
.build());
}
}
resources:
# You need to activate the link before you can return to the alarm contact information, otherwise diff will appear in terraform. So please confirm the activation link as soon as possible. Besides, you can ignore the diff of the alarm contact information by `lifestyle`.
example:
type: alicloud:cms:AlarmContact
properties:
alarmContactName: tf-example
describe: For example
channelsMail: terraform@test.com
Import
Alarm contact can be imported using the id, e.g.
$ pulumi import alicloud:cms/alarmContact:AlarmContact example abc12345
Properties
The name of the alarm contact. The length should between 2 and 40 characters.
The TradeManager ID of the alarm contact.
The webhook URL of the DingTalk chatbot.
The email address of the alarm contact. After you add or modify an email address, the recipient receives an email that contains an activation link. The system adds the recipient to the list of alarm contacts only after the recipient activates the email address.
The phone number of the alarm contact. After you add or modify an email address, the recipient receives an email that contains an activation link. The system adds the recipient to the list of alarm contacts only after the recipient activates the email address.