1. Packages
  2. Flexibleengine Provider
  3. API Docs
  4. AsNotification
flexibleengine 1.46.0 published on Monday, Apr 14, 2025 by flexibleenginecloud

flexibleengine.AsNotification

Explore with Pulumi AI

flexibleengine logo
flexibleengine 1.46.0 published on Monday, Apr 14, 2025 by flexibleenginecloud

    Manages an AS notification resource within FlexibleEngine.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as flexibleengine from "@pulumi/flexibleengine";
    
    const config = new pulumi.Config();
    const scalingGroupId = config.requireObject("scalingGroupId");
    const topicUrn = config.requireObject("topicUrn");
    const events = config.requireObject<Array<string>>("events");
    const test = new flexibleengine.AsNotification("test", {
        scalingGroupId: scalingGroupId,
        topicUrn: topicUrn,
        events: events,
    });
    
    import pulumi
    import pulumi_flexibleengine as flexibleengine
    
    config = pulumi.Config()
    scaling_group_id = config.require_object("scalingGroupId")
    topic_urn = config.require_object("topicUrn")
    events = config.require_object("events")
    test = flexibleengine.AsNotification("test",
        scaling_group_id=scaling_group_id,
        topic_urn=topic_urn,
        events=events)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/flexibleengine/flexibleengine"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		scalingGroupId := cfg.RequireObject("scalingGroupId")
    		topicUrn := cfg.RequireObject("topicUrn")
    		events := cfg.Require("events")
    		_, err := flexibleengine.NewAsNotification(ctx, "test", &flexibleengine.AsNotificationArgs{
    			ScalingGroupId: pulumi.Any(scalingGroupId),
    			TopicUrn:       pulumi.Any(topicUrn),
    			Events:         events,
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Flexibleengine = Pulumi.Flexibleengine;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var scalingGroupId = config.RequireObject<dynamic>("scalingGroupId");
        var topicUrn = config.RequireObject<dynamic>("topicUrn");
        var events = config.RequireObject<string[]>("events");
        var test = new Flexibleengine.AsNotification("test", new()
        {
            ScalingGroupId = scalingGroupId,
            TopicUrn = topicUrn,
            Events = events,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.flexibleengine.AsNotification;
    import com.pulumi.flexibleengine.AsNotificationArgs;
    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) {
            final var config = ctx.config();
            final var scalingGroupId = config.get("scalingGroupId");
            final var topicUrn = config.get("topicUrn");
            final var events = config.get("events");
            var test = new AsNotification("test", AsNotificationArgs.builder()
                .scalingGroupId(scalingGroupId)
                .topicUrn(topicUrn)
                .events(events)
                .build());
    
        }
    }
    
    configuration:
      scalingGroupId:
        type: dynamic
      topicUrn:
        type: dynamic
      events:
        type: list(string)
    resources:
      test:
        type: flexibleengine:AsNotification
        properties:
          scalingGroupId: ${scalingGroupId}
          topicUrn: ${topicUrn}
          events: ${events}
    

    Create AsNotification Resource

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

    Constructor syntax

    new AsNotification(name: string, args: AsNotificationArgs, opts?: CustomResourceOptions);
    @overload
    def AsNotification(resource_name: str,
                       args: AsNotificationArgs,
                       opts: Optional[ResourceOptions] = None)
    
    @overload
    def AsNotification(resource_name: str,
                       opts: Optional[ResourceOptions] = None,
                       events: Optional[Sequence[str]] = None,
                       scaling_group_id: Optional[str] = None,
                       topic_urn: Optional[str] = None,
                       as_notification_id: Optional[str] = None,
                       region: Optional[str] = None)
    func NewAsNotification(ctx *Context, name string, args AsNotificationArgs, opts ...ResourceOption) (*AsNotification, error)
    public AsNotification(string name, AsNotificationArgs args, CustomResourceOptions? opts = null)
    public AsNotification(String name, AsNotificationArgs args)
    public AsNotification(String name, AsNotificationArgs args, CustomResourceOptions options)
    
    type: flexibleengine:AsNotification
    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 AsNotificationArgs
    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 AsNotificationArgs
    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 AsNotificationArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args AsNotificationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args AsNotificationArgs
    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 asNotificationResource = new Flexibleengine.AsNotification("asNotificationResource", new()
    {
        Events = new[]
        {
            "string",
        },
        ScalingGroupId = "string",
        TopicUrn = "string",
        AsNotificationId = "string",
        Region = "string",
    });
    
    example, err := flexibleengine.NewAsNotification(ctx, "asNotificationResource", &flexibleengine.AsNotificationArgs{
    	Events: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	ScalingGroupId:   pulumi.String("string"),
    	TopicUrn:         pulumi.String("string"),
    	AsNotificationId: pulumi.String("string"),
    	Region:           pulumi.String("string"),
    })
    
    var asNotificationResource = new AsNotification("asNotificationResource", AsNotificationArgs.builder()
        .events("string")
        .scalingGroupId("string")
        .topicUrn("string")
        .asNotificationId("string")
        .region("string")
        .build());
    
    as_notification_resource = flexibleengine.AsNotification("asNotificationResource",
        events=["string"],
        scaling_group_id="string",
        topic_urn="string",
        as_notification_id="string",
        region="string")
    
    const asNotificationResource = new flexibleengine.AsNotification("asNotificationResource", {
        events: ["string"],
        scalingGroupId: "string",
        topicUrn: "string",
        asNotificationId: "string",
        region: "string",
    });
    
    type: flexibleengine:AsNotification
    properties:
        asNotificationId: string
        events:
            - string
        region: string
        scalingGroupId: string
        topicUrn: string
    

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

    Events List<string>
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    ScalingGroupId string
    Specifies the AS group ID. Changing this creates a new AS notification.
    TopicUrn string
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    AsNotificationId string
    The unique topic URN in SMN.
    Region string
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    Events []string
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    ScalingGroupId string
    Specifies the AS group ID. Changing this creates a new AS notification.
    TopicUrn string
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    AsNotificationId string
    The unique topic URN in SMN.
    Region string
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    events List<String>
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    scalingGroupId String
    Specifies the AS group ID. Changing this creates a new AS notification.
    topicUrn String
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    asNotificationId String
    The unique topic URN in SMN.
    region String
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    events string[]
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    scalingGroupId string
    Specifies the AS group ID. Changing this creates a new AS notification.
    topicUrn string
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    asNotificationId string
    The unique topic URN in SMN.
    region string
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    events Sequence[str]
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    scaling_group_id str
    Specifies the AS group ID. Changing this creates a new AS notification.
    topic_urn str
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    as_notification_id str
    The unique topic URN in SMN.
    region str
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    events List<String>
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    scalingGroupId String
    Specifies the AS group ID. Changing this creates a new AS notification.
    topicUrn String
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    asNotificationId String
    The unique topic URN in SMN.
    region String
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    TopicName string
    The topic name in SMN.
    Id string
    The provider-assigned unique ID for this managed resource.
    TopicName string
    The topic name in SMN.
    id String
    The provider-assigned unique ID for this managed resource.
    topicName String
    The topic name in SMN.
    id string
    The provider-assigned unique ID for this managed resource.
    topicName string
    The topic name in SMN.
    id str
    The provider-assigned unique ID for this managed resource.
    topic_name str
    The topic name in SMN.
    id String
    The provider-assigned unique ID for this managed resource.
    topicName String
    The topic name in SMN.

    Look up Existing AsNotification Resource

    Get an existing AsNotification 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?: AsNotificationState, opts?: CustomResourceOptions): AsNotification
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            as_notification_id: Optional[str] = None,
            events: Optional[Sequence[str]] = None,
            region: Optional[str] = None,
            scaling_group_id: Optional[str] = None,
            topic_name: Optional[str] = None,
            topic_urn: Optional[str] = None) -> AsNotification
    func GetAsNotification(ctx *Context, name string, id IDInput, state *AsNotificationState, opts ...ResourceOption) (*AsNotification, error)
    public static AsNotification Get(string name, Input<string> id, AsNotificationState? state, CustomResourceOptions? opts = null)
    public static AsNotification get(String name, Output<String> id, AsNotificationState state, CustomResourceOptions options)
    resources:  _:    type: flexibleengine:AsNotification    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:
    AsNotificationId string
    The unique topic URN in SMN.
    Events List<string>
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    Region string
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    ScalingGroupId string
    Specifies the AS group ID. Changing this creates a new AS notification.
    TopicName string
    The topic name in SMN.
    TopicUrn string
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    AsNotificationId string
    The unique topic URN in SMN.
    Events []string
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    Region string
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    ScalingGroupId string
    Specifies the AS group ID. Changing this creates a new AS notification.
    TopicName string
    The topic name in SMN.
    TopicUrn string
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    asNotificationId String
    The unique topic URN in SMN.
    events List<String>
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    region String
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    scalingGroupId String
    Specifies the AS group ID. Changing this creates a new AS notification.
    topicName String
    The topic name in SMN.
    topicUrn String
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    asNotificationId string
    The unique topic URN in SMN.
    events string[]
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    region string
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    scalingGroupId string
    Specifies the AS group ID. Changing this creates a new AS notification.
    topicName string
    The topic name in SMN.
    topicUrn string
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    as_notification_id str
    The unique topic URN in SMN.
    events Sequence[str]
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    region str
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    scaling_group_id str
    Specifies the AS group ID. Changing this creates a new AS notification.
    topic_name str
    The topic name in SMN.
    topic_urn str
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.
    asNotificationId String
    The unique topic URN in SMN.
    events List<String>
    Specifies the topic scene of AS group. The events include SCALING_UP, SCALING_UP_FAIL, SCALING_DOWN, SCALING_DOWN_FAIL, SCALING_GROUP_ABNORMAL.
    region String
    Specifies the region in which to create the resource. If omitted, the provider-level region will be used. Changing this creates a new resource.
    scalingGroupId String
    Specifies the AS group ID. Changing this creates a new AS notification.
    topicName String
    The topic name in SMN.
    topicUrn String
    Specifies the unique topic URN of the SMN. Changing this creates a new AS notification.

    Import

    The as notification can be imported using scaling_group_id, topic_urn, separated by a slash, e.g.

    bash

    $ pulumi import flexibleengine:index/asNotification:AsNotification test <scaling_group_id>/<topic_urn>
    

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

    Package Details

    Repository
    flexibleengine flexibleenginecloud/terraform-provider-flexibleengine
    License
    Notes
    This Pulumi package is based on the flexibleengine Terraform Provider.
    flexibleengine logo
    flexibleengine 1.46.0 published on Monday, Apr 14, 2025 by flexibleenginecloud