Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.21.0 published on Tuesday, Jun 14, 2022 by Pulumi

getNotifications

This data source provides available notification resources.

NOTE: Available in 1.72.0+

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var ds = Output.Create(AliCloud.Ess.GetNotifications.InvokeAsync(new AliCloud.Ess.GetNotificationsArgs
        {
            ScalingGroupId = "scaling_group_id",
        }));
        this.FirstNotification = ds.Apply(ds => ds.Notifications?[0]?.Id);
    }

    [Output("firstNotification")]
    public Output<string> FirstNotification { get; set; }
}
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ds, err := ess.GetNotifications(ctx, &ess.GetNotificationsArgs{
			ScalingGroupId: "scaling_group_id",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("firstNotification", ds.Notifications[0].Id)
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

ds = alicloud.ess.get_notifications(scaling_group_id="scaling_group_id")
pulumi.export("firstNotification", ds.notifications[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const ds = pulumi.output(alicloud.ess.getNotifications({
    scalingGroupId: "scaling_group_id",
}));

export const firstNotification = ds.notifications[0].id;

Coming soon!

Using getNotifications

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getNotifications(args: GetNotificationsArgs, opts?: InvokeOptions): Promise<GetNotificationsResult>
function getNotificationsOutput(args: GetNotificationsOutputArgs, opts?: InvokeOptions): Output<GetNotificationsResult>
def get_notifications(ids: Optional[Sequence[str]] = None,
                      output_file: Optional[str] = None,
                      scaling_group_id: Optional[str] = None,
                      opts: Optional[InvokeOptions] = None) -> GetNotificationsResult
def get_notifications_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                      output_file: Optional[pulumi.Input[str]] = None,
                      scaling_group_id: Optional[pulumi.Input[str]] = None,
                      opts: Optional[InvokeOptions] = None) -> Output[GetNotificationsResult]
func GetNotifications(ctx *Context, args *GetNotificationsArgs, opts ...InvokeOption) (*GetNotificationsResult, error)
func GetNotificationsOutput(ctx *Context, args *GetNotificationsOutputArgs, opts ...InvokeOption) GetNotificationsResultOutput

> Note: This function is named GetNotifications in the Go SDK.

public static class GetNotifications 
{
    public static Task<GetNotificationsResult> InvokeAsync(GetNotificationsArgs args, InvokeOptions? opts = null)
    public static Output<GetNotificationsResult> Invoke(GetNotificationsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetNotificationsResult> getNotifications(GetNotificationsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: alicloud:ess/getNotifications:getNotifications
  Arguments:
    # Arguments dictionary

The following arguments are supported:

ScalingGroupId string

Scaling group id the notifications belong to.

Ids List<string>

A list of notification ids.

OutputFile string
ScalingGroupId string

Scaling group id the notifications belong to.

Ids []string

A list of notification ids.

OutputFile string
scalingGroupId String

Scaling group id the notifications belong to.

ids List<String>

A list of notification ids.

outputFile String
scalingGroupId string

Scaling group id the notifications belong to.

ids string[]

A list of notification ids.

outputFile string
scaling_group_id str

Scaling group id the notifications belong to.

ids Sequence[str]

A list of notification ids.

output_file str
scalingGroupId String

Scaling group id the notifications belong to.

ids List<String>

A list of notification ids.

outputFile String

getNotifications Result

The following output properties are available:

Id string

The provider-assigned unique ID for this managed resource.

Notifications List<Pulumi.AliCloud.Ess.Outputs.GetNotificationsNotification>

A list of notifications. Each element contains the following attributes:

ScalingGroupId string

ID of the scaling group.

Ids List<string>

A list of notification ids.

OutputFile string
Id string

The provider-assigned unique ID for this managed resource.

Notifications []GetNotificationsNotification

A list of notifications. Each element contains the following attributes:

ScalingGroupId string

ID of the scaling group.

Ids []string

A list of notification ids.

OutputFile string
id String

The provider-assigned unique ID for this managed resource.

notifications List<GetNotificationsNotification>

A list of notifications. Each element contains the following attributes:

scalingGroupId String

ID of the scaling group.

ids List<String>

A list of notification ids.

outputFile String
id string

The provider-assigned unique ID for this managed resource.

notifications GetNotificationsNotification[]

A list of notifications. Each element contains the following attributes:

scalingGroupId string

ID of the scaling group.

ids string[]

A list of notification ids.

outputFile string
id str

The provider-assigned unique ID for this managed resource.

notifications Sequence[GetNotificationsNotification]

A list of notifications. Each element contains the following attributes:

scaling_group_id str

ID of the scaling group.

ids Sequence[str]

A list of notification ids.

output_file str
id String

The provider-assigned unique ID for this managed resource.

notifications List<Property Map>

A list of notifications. Each element contains the following attributes:

scalingGroupId String

ID of the scaling group.

ids List<String>

A list of notification ids.

outputFile String

Supporting Types

GetNotificationsNotification

Id string

ID of the notification.

NotificationArn string

The Alibaba Cloud Resource Name (ARN) for the notification object.

NotificationTypes List<string>

The notification types of Auto Scaling events and resource changes.

ScalingGroupId string

Scaling group id the notifications belong to.

Id string

ID of the notification.

NotificationArn string

The Alibaba Cloud Resource Name (ARN) for the notification object.

NotificationTypes []string

The notification types of Auto Scaling events and resource changes.

ScalingGroupId string

Scaling group id the notifications belong to.

id String

ID of the notification.

notificationArn String

The Alibaba Cloud Resource Name (ARN) for the notification object.

notificationTypes List<String>

The notification types of Auto Scaling events and resource changes.

scalingGroupId String

Scaling group id the notifications belong to.

id string

ID of the notification.

notificationArn string

The Alibaba Cloud Resource Name (ARN) for the notification object.

notificationTypes string[]

The notification types of Auto Scaling events and resource changes.

scalingGroupId string

Scaling group id the notifications belong to.

id str

ID of the notification.

notification_arn str

The Alibaba Cloud Resource Name (ARN) for the notification object.

notification_types Sequence[str]

The notification types of Auto Scaling events and resource changes.

scaling_group_id str

Scaling group id the notifications belong to.

id String

ID of the notification.

notificationArn String

The Alibaba Cloud Resource Name (ARN) for the notification object.

notificationTypes List<String>

The notification types of Auto Scaling events and resource changes.

scalingGroupId String

Scaling group id the notifications belong to.

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.