1. Packages
  2. AWS Classic
  3. API Docs
  4. devopsguru
  5. NotificationChannel

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.36.0 published on Wednesday, May 15, 2024 by Pulumi

aws.devopsguru.NotificationChannel

Explore with Pulumi AI

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.36.0 published on Wednesday, May 15, 2024 by Pulumi

    Resource for managing an AWS DevOps Guru Notification Channel.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.devopsguru.NotificationChannel("example", {sns: {
        topicArn: exampleAwsSnsTopic.arn,
    }});
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.devopsguru.NotificationChannel("example", sns=aws.devopsguru.NotificationChannelSnsArgs(
        topic_arn=example_aws_sns_topic["arn"],
    ))
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/devopsguru"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := devopsguru.NewNotificationChannel(ctx, "example", &devopsguru.NotificationChannelArgs{
    			Sns: &devopsguru.NotificationChannelSnsArgs{
    				TopicArn: pulumi.Any(exampleAwsSnsTopic.Arn),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Aws.DevOpsGuru.NotificationChannel("example", new()
        {
            Sns = new Aws.DevOpsGuru.Inputs.NotificationChannelSnsArgs
            {
                TopicArn = exampleAwsSnsTopic.Arn,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.devopsguru.NotificationChannel;
    import com.pulumi.aws.devopsguru.NotificationChannelArgs;
    import com.pulumi.aws.devopsguru.inputs.NotificationChannelSnsArgs;
    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 NotificationChannel("example", NotificationChannelArgs.builder()        
                .sns(NotificationChannelSnsArgs.builder()
                    .topicArn(exampleAwsSnsTopic.arn())
                    .build())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:devopsguru:NotificationChannel
        properties:
          sns:
            topicArn: ${exampleAwsSnsTopic.arn}
    

    Filters

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.devopsguru.NotificationChannel("example", {
        sns: {
            topicArn: exampleAwsSnsTopic.arn,
        },
        filters: {
            messageTypes: ["NEW_INSIGHT"],
            severities: ["HIGH"],
        },
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.devopsguru.NotificationChannel("example",
        sns=aws.devopsguru.NotificationChannelSnsArgs(
            topic_arn=example_aws_sns_topic["arn"],
        ),
        filters=aws.devopsguru.NotificationChannelFiltersArgs(
            message_types=["NEW_INSIGHT"],
            severities=["HIGH"],
        ))
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/devopsguru"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := devopsguru.NewNotificationChannel(ctx, "example", &devopsguru.NotificationChannelArgs{
    			Sns: &devopsguru.NotificationChannelSnsArgs{
    				TopicArn: pulumi.Any(exampleAwsSnsTopic.Arn),
    			},
    			Filters: &devopsguru.NotificationChannelFiltersArgs{
    				MessageTypes: pulumi.StringArray{
    					pulumi.String("NEW_INSIGHT"),
    				},
    				Severities: pulumi.StringArray{
    					pulumi.String("HIGH"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Aws.DevOpsGuru.NotificationChannel("example", new()
        {
            Sns = new Aws.DevOpsGuru.Inputs.NotificationChannelSnsArgs
            {
                TopicArn = exampleAwsSnsTopic.Arn,
            },
            Filters = new Aws.DevOpsGuru.Inputs.NotificationChannelFiltersArgs
            {
                MessageTypes = new[]
                {
                    "NEW_INSIGHT",
                },
                Severities = new[]
                {
                    "HIGH",
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.devopsguru.NotificationChannel;
    import com.pulumi.aws.devopsguru.NotificationChannelArgs;
    import com.pulumi.aws.devopsguru.inputs.NotificationChannelSnsArgs;
    import com.pulumi.aws.devopsguru.inputs.NotificationChannelFiltersArgs;
    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 NotificationChannel("example", NotificationChannelArgs.builder()        
                .sns(NotificationChannelSnsArgs.builder()
                    .topicArn(exampleAwsSnsTopic.arn())
                    .build())
                .filters(NotificationChannelFiltersArgs.builder()
                    .messageTypes("NEW_INSIGHT")
                    .severities("HIGH")
                    .build())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:devopsguru:NotificationChannel
        properties:
          sns:
            topicArn: ${exampleAwsSnsTopic.arn}
          filters:
            messageTypes:
              - NEW_INSIGHT
            severities:
              - HIGH
    

    Create NotificationChannel Resource

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

    Constructor syntax

    new NotificationChannel(name: string, args?: NotificationChannelArgs, opts?: CustomResourceOptions);
    @overload
    def NotificationChannel(resource_name: str,
                            args: Optional[NotificationChannelArgs] = None,
                            opts: Optional[ResourceOptions] = None)
    
    @overload
    def NotificationChannel(resource_name: str,
                            opts: Optional[ResourceOptions] = None,
                            filters: Optional[NotificationChannelFiltersArgs] = None,
                            sns: Optional[NotificationChannelSnsArgs] = None)
    func NewNotificationChannel(ctx *Context, name string, args *NotificationChannelArgs, opts ...ResourceOption) (*NotificationChannel, error)
    public NotificationChannel(string name, NotificationChannelArgs? args = null, CustomResourceOptions? opts = null)
    public NotificationChannel(String name, NotificationChannelArgs args)
    public NotificationChannel(String name, NotificationChannelArgs args, CustomResourceOptions options)
    
    type: aws:devopsguru:NotificationChannel
    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 NotificationChannelArgs
    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 NotificationChannelArgs
    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 NotificationChannelArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args NotificationChannelArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args NotificationChannelArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

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

    var notificationChannelResource = new Aws.DevOpsGuru.NotificationChannel("notificationChannelResource", new()
    {
        Filters = new Aws.DevOpsGuru.Inputs.NotificationChannelFiltersArgs
        {
            MessageTypes = new[]
            {
                "string",
            },
            Severities = new[]
            {
                "string",
            },
        },
        Sns = new Aws.DevOpsGuru.Inputs.NotificationChannelSnsArgs
        {
            TopicArn = "string",
        },
    });
    
    example, err := devopsguru.NewNotificationChannel(ctx, "notificationChannelResource", &devopsguru.NotificationChannelArgs{
    	Filters: &devopsguru.NotificationChannelFiltersArgs{
    		MessageTypes: pulumi.StringArray{
    			pulumi.String("string"),
    		},
    		Severities: pulumi.StringArray{
    			pulumi.String("string"),
    		},
    	},
    	Sns: &devopsguru.NotificationChannelSnsArgs{
    		TopicArn: pulumi.String("string"),
    	},
    })
    
    var notificationChannelResource = new NotificationChannel("notificationChannelResource", NotificationChannelArgs.builder()        
        .filters(NotificationChannelFiltersArgs.builder()
            .messageTypes("string")
            .severities("string")
            .build())
        .sns(NotificationChannelSnsArgs.builder()
            .topicArn("string")
            .build())
        .build());
    
    notification_channel_resource = aws.devopsguru.NotificationChannel("notificationChannelResource",
        filters=aws.devopsguru.NotificationChannelFiltersArgs(
            message_types=["string"],
            severities=["string"],
        ),
        sns=aws.devopsguru.NotificationChannelSnsArgs(
            topic_arn="string",
        ))
    
    const notificationChannelResource = new aws.devopsguru.NotificationChannel("notificationChannelResource", {
        filters: {
            messageTypes: ["string"],
            severities: ["string"],
        },
        sns: {
            topicArn: "string",
        },
    });
    
    type: aws:devopsguru:NotificationChannel
    properties:
        filters:
            messageTypes:
                - string
            severities:
                - string
        sns:
            topicArn: string
    

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

    Filters NotificationChannelFilters
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    Sns NotificationChannelSns

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    Filters NotificationChannelFiltersArgs
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    Sns NotificationChannelSnsArgs

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters NotificationChannelFilters
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns NotificationChannelSns

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters NotificationChannelFilters
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns NotificationChannelSns

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters NotificationChannelFiltersArgs
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns NotificationChannelSnsArgs

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters Property Map
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns Property Map

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    Outputs

    All input properties are implicitly available as output properties. Additionally, the NotificationChannel 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 NotificationChannel Resource

    Get an existing NotificationChannel 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?: NotificationChannelState, opts?: CustomResourceOptions): NotificationChannel
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            filters: Optional[NotificationChannelFiltersArgs] = None,
            sns: Optional[NotificationChannelSnsArgs] = None) -> NotificationChannel
    func GetNotificationChannel(ctx *Context, name string, id IDInput, state *NotificationChannelState, opts ...ResourceOption) (*NotificationChannel, error)
    public static NotificationChannel Get(string name, Input<string> id, NotificationChannelState? state, CustomResourceOptions? opts = null)
    public static NotificationChannel get(String name, Output<String> id, NotificationChannelState 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:
    Filters NotificationChannelFilters
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    Sns NotificationChannelSns

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    Filters NotificationChannelFiltersArgs
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    Sns NotificationChannelSnsArgs

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters NotificationChannelFilters
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns NotificationChannelSns

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters NotificationChannelFilters
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns NotificationChannelSns

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters NotificationChannelFiltersArgs
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns NotificationChannelSnsArgs

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    filters Property Map
    Filter configurations for the Amazon SNS notification topic. See the filters argument reference below.
    sns Property Map

    SNS noficiation channel configurations. See the sns argument reference below.

    The following arguments are optional:

    Supporting Types

    NotificationChannelFilters, NotificationChannelFiltersArgs

    MessageTypes List<string>
    Events to receive notifications for. Valid values are NEW_INSIGHT, CLOSED_INSIGHT, NEW_ASSOCIATION, SEVERITY_UPGRADED, and NEW_RECOMMENDATION.
    Severities List<string>
    Severity levels to receive notifications for. Valid values are LOW, MEDIUM, and HIGH.
    MessageTypes []string
    Events to receive notifications for. Valid values are NEW_INSIGHT, CLOSED_INSIGHT, NEW_ASSOCIATION, SEVERITY_UPGRADED, and NEW_RECOMMENDATION.
    Severities []string
    Severity levels to receive notifications for. Valid values are LOW, MEDIUM, and HIGH.
    messageTypes List<String>
    Events to receive notifications for. Valid values are NEW_INSIGHT, CLOSED_INSIGHT, NEW_ASSOCIATION, SEVERITY_UPGRADED, and NEW_RECOMMENDATION.
    severities List<String>
    Severity levels to receive notifications for. Valid values are LOW, MEDIUM, and HIGH.
    messageTypes string[]
    Events to receive notifications for. Valid values are NEW_INSIGHT, CLOSED_INSIGHT, NEW_ASSOCIATION, SEVERITY_UPGRADED, and NEW_RECOMMENDATION.
    severities string[]
    Severity levels to receive notifications for. Valid values are LOW, MEDIUM, and HIGH.
    message_types Sequence[str]
    Events to receive notifications for. Valid values are NEW_INSIGHT, CLOSED_INSIGHT, NEW_ASSOCIATION, SEVERITY_UPGRADED, and NEW_RECOMMENDATION.
    severities Sequence[str]
    Severity levels to receive notifications for. Valid values are LOW, MEDIUM, and HIGH.
    messageTypes List<String>
    Events to receive notifications for. Valid values are NEW_INSIGHT, CLOSED_INSIGHT, NEW_ASSOCIATION, SEVERITY_UPGRADED, and NEW_RECOMMENDATION.
    severities List<String>
    Severity levels to receive notifications for. Valid values are LOW, MEDIUM, and HIGH.

    NotificationChannelSns, NotificationChannelSnsArgs

    TopicArn string
    Amazon Resource Name (ARN) of an Amazon Simple Notification Service topic.
    TopicArn string
    Amazon Resource Name (ARN) of an Amazon Simple Notification Service topic.
    topicArn String
    Amazon Resource Name (ARN) of an Amazon Simple Notification Service topic.
    topicArn string
    Amazon Resource Name (ARN) of an Amazon Simple Notification Service topic.
    topic_arn str
    Amazon Resource Name (ARN) of an Amazon Simple Notification Service topic.
    topicArn String
    Amazon Resource Name (ARN) of an Amazon Simple Notification Service topic.

    Import

    Using pulumi import, import DevOps Guru Notification Channel using the id. For example:

    $ pulumi import aws:devopsguru/notificationChannel:NotificationChannel example id-12345678
    

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

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.36.0 published on Wednesday, May 15, 2024 by Pulumi