Welcome to Pulumi Registry, your window into the cloud. Read the announcement.

Alibaba Cloud

v3.8.0 published on Monday, Oct 4, 2021 by Pulumi

getBandwidthPackages

This data source provides the Global Accelerator (GA) Bandwidth Packages of the current Alibaba Cloud user.

NOTE: Available in v1.112.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var example = Output.Create(AliCloud.Ga.GetBandwidthPackages.InvokeAsync(new AliCloud.Ga.GetBandwidthPackagesArgs
        {
            Ids = 
            {
                "example_value",
            },
            NameRegex = "the_resource_name",
        }));
        this.FirstGaBandwidthPackageId = example.Apply(example => example.Packages[0].Id);
    }

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

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		opt0 := "the_resource_name"
		example, err := ga.GetBandwidthPackages(ctx, &ga.GetBandwidthPackagesArgs{
			Ids: []string{
				"example_value",
			},
			NameRegex: &opt0,
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("firstGaBandwidthPackageId", example.Packages[0].Id)
		return nil
	})
}
import pulumi
import pulumi_alicloud as alicloud

example = alicloud.ga.get_bandwidth_packages(ids=["example_value"],
    name_regex="the_resource_name")
pulumi.export("firstGaBandwidthPackageId", example.packages[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const example = alicloud.ga.getBandwidthPackages({
    ids: ["example_value"],
    nameRegex: "the_resource_name",
});
export const firstGaBandwidthPackageId = example.then(example => example.packages[0].id);

Using getBandwidthPackages

function getBandwidthPackages(args: GetBandwidthPackagesArgs, opts?: InvokeOptions): Promise<GetBandwidthPackagesResult>
def get_bandwidth_packages(enable_details: Optional[bool] = None,
                           ids: Optional[Sequence[str]] = None,
                           name_regex: Optional[str] = None,
                           output_file: Optional[str] = None,
                           status: Optional[str] = None,
                           type: Optional[str] = None,
                           opts: Optional[InvokeOptions] = None) -> GetBandwidthPackagesResult
func GetBandwidthPackages(ctx *Context, args *GetBandwidthPackagesArgs, opts ...InvokeOption) (*GetBandwidthPackagesResult, error)

Note: This function is named GetBandwidthPackages in the Go SDK.

public static class GetBandwidthPackages {
    public static Task<GetBandwidthPackagesResult> InvokeAsync(GetBandwidthPackagesArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

EnableDetails bool
Default to false. Set it to true can output more details about resource attributes.
Ids List<string>
A list of Bandwidth Package IDs.
NameRegex string
A regex string to filter results by Bandwidth Package name.
OutputFile string
Status string
The status of the bandwidth plan.
Type string
The type of the bandwidth packet. China station only supports return to basic.
EnableDetails bool
Default to false. Set it to true can output more details about resource attributes.
Ids []string
A list of Bandwidth Package IDs.
NameRegex string
A regex string to filter results by Bandwidth Package name.
OutputFile string
Status string
The status of the bandwidth plan.
Type string
The type of the bandwidth packet. China station only supports return to basic.
enableDetails boolean
Default to false. Set it to true can output more details about resource attributes.
ids string[]
A list of Bandwidth Package IDs.
nameRegex string
A regex string to filter results by Bandwidth Package name.
outputFile string
status string
The status of the bandwidth plan.
type string
The type of the bandwidth packet. China station only supports return to basic.
enable_details bool
Default to false. Set it to true can output more details about resource attributes.
ids Sequence[str]
A list of Bandwidth Package IDs.
name_regex str
A regex string to filter results by Bandwidth Package name.
output_file str
status str
The status of the bandwidth plan.
type str
The type of the bandwidth packet. China station only supports return to basic.

getBandwidthPackages Result

The following output properties are available:

Id string
The provider-assigned unique ID for this managed resource.
Ids List<string>
Names List<string>
Packages List<Pulumi.AliCloud.Ga.Outputs.GetBandwidthPackagesPackage>
EnableDetails bool
NameRegex string
OutputFile string
Status string
Type string
Id string
The provider-assigned unique ID for this managed resource.
Ids []string
Names []string
Packages []GetBandwidthPackagesPackage
EnableDetails bool
NameRegex string
OutputFile string
Status string
Type string
id string
The provider-assigned unique ID for this managed resource.
ids string[]
names string[]
packages GetBandwidthPackagesPackage[]
enableDetails boolean
nameRegex string
outputFile string
status string
type string
id str
The provider-assigned unique ID for this managed resource.
ids Sequence[str]
names Sequence[str]
packages Sequence[GetBandwidthPackagesPackage]
enable_details bool
name_regex str
output_file str
status str
type str

Supporting Types

GetBandwidthPackagesPackage

Bandwidth int
The bandwidth value of bandwidth packet.
BandwidthPackageId string
The Resource ID of the bandwidth.
BandwidthPackageName string
The name of the bandwidth packet.
BandwidthType string
The bandwidth type of the bandwidth.
CbnGeographicRegionIda string
Interworking area A of cross domain acceleration package. Only international stations support returning this parameter.
CbnGeographicRegionIdb string
Interworking area B of cross domain acceleration package. Only international stations support returning this parameter.
Description string
The description of bandwidth package.
ExpiredTime string
Bandwidth package expiration time.
Id string
The ID of the Bandwidth Package.
PaymentType string
The payment type of the bandwidth.
Status string
The status of the bandwidth plan.
Type string
The type of the bandwidth packet. China station only supports return to basic.
Bandwidth int
The bandwidth value of bandwidth packet.
BandwidthPackageId string
The Resource ID of the bandwidth.
BandwidthPackageName string
The name of the bandwidth packet.
BandwidthType string
The bandwidth type of the bandwidth.
CbnGeographicRegionIda string
Interworking area A of cross domain acceleration package. Only international stations support returning this parameter.
CbnGeographicRegionIdb string
Interworking area B of cross domain acceleration package. Only international stations support returning this parameter.
Description string
The description of bandwidth package.
ExpiredTime string
Bandwidth package expiration time.
Id string
The ID of the Bandwidth Package.
PaymentType string
The payment type of the bandwidth.
Status string
The status of the bandwidth plan.
Type string
The type of the bandwidth packet. China station only supports return to basic.
bandwidth number
The bandwidth value of bandwidth packet.
bandwidthPackageId string
The Resource ID of the bandwidth.
bandwidthPackageName string
The name of the bandwidth packet.
bandwidthType string
The bandwidth type of the bandwidth.
cbnGeographicRegionIda string
Interworking area A of cross domain acceleration package. Only international stations support returning this parameter.
cbnGeographicRegionIdb string
Interworking area B of cross domain acceleration package. Only international stations support returning this parameter.
description string
The description of bandwidth package.
expiredTime string
Bandwidth package expiration time.
id string
The ID of the Bandwidth Package.
paymentType string
The payment type of the bandwidth.
status string
The status of the bandwidth plan.
type string
The type of the bandwidth packet. China station only supports return to basic.
bandwidth int
The bandwidth value of bandwidth packet.
bandwidth_package_id str
The Resource ID of the bandwidth.
bandwidth_package_name str
The name of the bandwidth packet.
bandwidth_type str
The bandwidth type of the bandwidth.
cbn_geographic_region_ida str
Interworking area A of cross domain acceleration package. Only international stations support returning this parameter.
cbn_geographic_region_idb str
Interworking area B of cross domain acceleration package. Only international stations support returning this parameter.
description str
The description of bandwidth package.
expired_time str
Bandwidth package expiration time.
id str
The ID of the Bandwidth Package.
payment_type str
The payment type of the bandwidth.
status str
The status of the bandwidth plan.
type str
The type of the bandwidth packet. China station only supports return to basic.

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.