1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. bss
  5. getOpenApiPricingModules
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.bss.getOpenApiPricingModules

Explore with Pulumi AI

This data source provides Bss Open Api Pricing Module available to the user.What is Pricing Module

NOTE: Available since v1.195.0.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const _default = alicloud.bss.getOpenApiPricingModules({
    nameRegex: "国内月均日峰值带宽",
    productCode: "cdn",
    productType: "CDN",
    subscriptionType: "PayAsYouGo",
});
export const alicloudBssOpenapiPricingModuleExampleId = _default.then(_default => _default.modules?.[0]?.code);
Copy
import pulumi
import pulumi_alicloud as alicloud

default = alicloud.bss.get_open_api_pricing_modules(name_regex="国内月均日峰值带宽",
    product_code="cdn",
    product_type="CDN",
    subscription_type="PayAsYouGo")
pulumi.export("alicloudBssOpenapiPricingModuleExampleId", default.modules[0].code)
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_default, err := bss.GetOpenApiPricingModules(ctx, &bss.GetOpenApiPricingModulesArgs{
			NameRegex:        pulumi.StringRef("国内月均日峰值带宽"),
			ProductCode:      "cdn",
			ProductType:      pulumi.StringRef("CDN"),
			SubscriptionType: "PayAsYouGo",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("alicloudBssOpenapiPricingModuleExampleId", _default.Modules[0].Code)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var @default = AliCloud.Bss.GetOpenApiPricingModules.Invoke(new()
    {
        NameRegex = "国内月均日峰值带宽",
        ProductCode = "cdn",
        ProductType = "CDN",
        SubscriptionType = "PayAsYouGo",
    });

    return new Dictionary<string, object?>
    {
        ["alicloudBssOpenapiPricingModuleExampleId"] = @default.Apply(@default => @default.Apply(getOpenApiPricingModulesResult => getOpenApiPricingModulesResult.Modules[0]?.Code)),
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.bss.BssFunctions;
import com.pulumi.alicloud.bss.inputs.GetOpenApiPricingModulesArgs;
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 default = BssFunctions.getOpenApiPricingModules(GetOpenApiPricingModulesArgs.builder()
            .nameRegex("国内月均日峰值带宽")
            .productCode("cdn")
            .productType("CDN")
            .subscriptionType("PayAsYouGo")
            .build());

        ctx.export("alicloudBssOpenapiPricingModuleExampleId", default_.modules()[0].code());
    }
}
Copy
variables:
  default:
    fn::invoke:
      function: alicloud:bss:getOpenApiPricingModules
      arguments:
        nameRegex: 国内月均日峰值带宽
        productCode: cdn
        productType: CDN
        subscriptionType: PayAsYouGo
outputs:
  alicloudBssOpenapiPricingModuleExampleId: ${default.modules[0].code}
Copy

Using getOpenApiPricingModules

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 getOpenApiPricingModules(args: GetOpenApiPricingModulesArgs, opts?: InvokeOptions): Promise<GetOpenApiPricingModulesResult>
function getOpenApiPricingModulesOutput(args: GetOpenApiPricingModulesOutputArgs, opts?: InvokeOptions): Output<GetOpenApiPricingModulesResult>
Copy
def get_open_api_pricing_modules(ids: Optional[Sequence[str]] = None,
                                 name_regex: Optional[str] = None,
                                 output_file: Optional[str] = None,
                                 product_code: Optional[str] = None,
                                 product_type: Optional[str] = None,
                                 subscription_type: Optional[str] = None,
                                 opts: Optional[InvokeOptions] = None) -> GetOpenApiPricingModulesResult
def get_open_api_pricing_modules_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                                 name_regex: Optional[pulumi.Input[str]] = None,
                                 output_file: Optional[pulumi.Input[str]] = None,
                                 product_code: Optional[pulumi.Input[str]] = None,
                                 product_type: Optional[pulumi.Input[str]] = None,
                                 subscription_type: Optional[pulumi.Input[str]] = None,
                                 opts: Optional[InvokeOptions] = None) -> Output[GetOpenApiPricingModulesResult]
Copy
func GetOpenApiPricingModules(ctx *Context, args *GetOpenApiPricingModulesArgs, opts ...InvokeOption) (*GetOpenApiPricingModulesResult, error)
func GetOpenApiPricingModulesOutput(ctx *Context, args *GetOpenApiPricingModulesOutputArgs, opts ...InvokeOption) GetOpenApiPricingModulesResultOutput
Copy

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

public static class GetOpenApiPricingModules 
{
    public static Task<GetOpenApiPricingModulesResult> InvokeAsync(GetOpenApiPricingModulesArgs args, InvokeOptions? opts = null)
    public static Output<GetOpenApiPricingModulesResult> Invoke(GetOpenApiPricingModulesInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetOpenApiPricingModulesResult> getOpenApiPricingModules(GetOpenApiPricingModulesArgs args, InvokeOptions options)
public static Output<GetOpenApiPricingModulesResult> getOpenApiPricingModules(GetOpenApiPricingModulesArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: alicloud:bss/getOpenApiPricingModules:getOpenApiPricingModules
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

ProductCode
This property is required.
Changes to this property will trigger replacement.
string
The product code.
SubscriptionType
This property is required.
Changes to this property will trigger replacement.
string
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
Ids List<string>
NameRegex Changes to this property will trigger replacement. string
A regex string to filter results by Property name.
OutputFile string
File name where to save data source results (after running pulumi preview).
ProductType Changes to this property will trigger replacement. string
The product type.
ProductCode
This property is required.
Changes to this property will trigger replacement.
string
The product code.
SubscriptionType
This property is required.
Changes to this property will trigger replacement.
string
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
Ids []string
NameRegex Changes to this property will trigger replacement. string
A regex string to filter results by Property name.
OutputFile string
File name where to save data source results (after running pulumi preview).
ProductType Changes to this property will trigger replacement. string
The product type.
productCode
This property is required.
Changes to this property will trigger replacement.
String
The product code.
subscriptionType
This property is required.
Changes to this property will trigger replacement.
String
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
ids List<String>
nameRegex Changes to this property will trigger replacement. String
A regex string to filter results by Property name.
outputFile String
File name where to save data source results (after running pulumi preview).
productType Changes to this property will trigger replacement. String
The product type.
productCode
This property is required.
Changes to this property will trigger replacement.
string
The product code.
subscriptionType
This property is required.
Changes to this property will trigger replacement.
string
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
ids string[]
nameRegex Changes to this property will trigger replacement. string
A regex string to filter results by Property name.
outputFile string
File name where to save data source results (after running pulumi preview).
productType Changes to this property will trigger replacement. string
The product type.
product_code
This property is required.
Changes to this property will trigger replacement.
str
The product code.
subscription_type
This property is required.
Changes to this property will trigger replacement.
str
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
ids Sequence[str]
name_regex Changes to this property will trigger replacement. str
A regex string to filter results by Property name.
output_file str
File name where to save data source results (after running pulumi preview).
product_type Changes to this property will trigger replacement. str
The product type.
productCode
This property is required.
Changes to this property will trigger replacement.
String
The product code.
subscriptionType
This property is required.
Changes to this property will trigger replacement.
String
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
ids List<String>
nameRegex Changes to this property will trigger replacement. String
A regex string to filter results by Property name.
outputFile String
File name where to save data source results (after running pulumi preview).
productType Changes to this property will trigger replacement. String
The product type.

getOpenApiPricingModules Result

The following output properties are available:

Id string
The provider-assigned unique ID for this managed resource.
Ids List<string>
Modules List<Pulumi.AliCloud.Bss.Outputs.GetOpenApiPricingModulesModule>
A list of Pricing Module Entries. Each element contains the following attributes:
Names List<string>
A list of name of Pricing Modules.
ProductCode string
SubscriptionType string
NameRegex string
OutputFile string
ProductType string
Id string
The provider-assigned unique ID for this managed resource.
Ids []string
Modules []GetOpenApiPricingModulesModule
A list of Pricing Module Entries. Each element contains the following attributes:
Names []string
A list of name of Pricing Modules.
ProductCode string
SubscriptionType string
NameRegex string
OutputFile string
ProductType string
id String
The provider-assigned unique ID for this managed resource.
ids List<String>
modules List<GetOpenApiPricingModulesModule>
A list of Pricing Module Entries. Each element contains the following attributes:
names List<String>
A list of name of Pricing Modules.
productCode String
subscriptionType String
nameRegex String
outputFile String
productType String
id string
The provider-assigned unique ID for this managed resource.
ids string[]
modules GetOpenApiPricingModulesModule[]
A list of Pricing Module Entries. Each element contains the following attributes:
names string[]
A list of name of Pricing Modules.
productCode string
subscriptionType string
nameRegex string
outputFile string
productType string
id str
The provider-assigned unique ID for this managed resource.
ids Sequence[str]
modules Sequence[GetOpenApiPricingModulesModule]
A list of Pricing Module Entries. Each element contains the following attributes:
names Sequence[str]
A list of name of Pricing Modules.
product_code str
subscription_type str
name_regex str
output_file str
product_type str
id String
The provider-assigned unique ID for this managed resource.
ids List<String>
modules List<Property Map>
A list of Pricing Module Entries. Each element contains the following attributes:
names List<String>
A list of name of Pricing Modules.
productCode String
subscriptionType String
nameRegex String
outputFile String
productType String

Supporting Types

GetOpenApiPricingModulesModule

Code This property is required. string
Property Code.
Id This property is required. string
A list of Price Module IDs.
PricingModuleName This property is required. string
Attribute name.
ProductCode This property is required. string
The product code.
ProductType This property is required. string
The product type.
SubscriptionType This property is required. string
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
Unit This property is required. string
Attribute unit.
Values This property is required. List<Pulumi.AliCloud.Bss.Inputs.GetOpenApiPricingModulesModuleValue>
Property.
Code This property is required. string
Property Code.
Id This property is required. string
A list of Price Module IDs.
PricingModuleName This property is required. string
Attribute name.
ProductCode This property is required. string
The product code.
ProductType This property is required. string
The product type.
SubscriptionType This property is required. string
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
Unit This property is required. string
Attribute unit.
Values This property is required. []GetOpenApiPricingModulesModuleValue
Property.
code This property is required. String
Property Code.
id This property is required. String
A list of Price Module IDs.
pricingModuleName This property is required. String
Attribute name.
productCode This property is required. String
The product code.
productType This property is required. String
The product type.
subscriptionType This property is required. String
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
unit This property is required. String
Attribute unit.
values This property is required. List<GetOpenApiPricingModulesModuleValue>
Property.
code This property is required. string
Property Code.
id This property is required. string
A list of Price Module IDs.
pricingModuleName This property is required. string
Attribute name.
productCode This property is required. string
The product code.
productType This property is required. string
The product type.
subscriptionType This property is required. string
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
unit This property is required. string
Attribute unit.
values This property is required. GetOpenApiPricingModulesModuleValue[]
Property.
code This property is required. str
Property Code.
id This property is required. str
A list of Price Module IDs.
pricing_module_name This property is required. str
Attribute name.
product_code This property is required. str
The product code.
product_type This property is required. str
The product type.
subscription_type This property is required. str
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
unit This property is required. str
Attribute unit.
values This property is required. Sequence[GetOpenApiPricingModulesModuleValue]
Property.
code This property is required. String
Property Code.
id This property is required. String
A list of Price Module IDs.
pricingModuleName This property is required. String
Attribute name.
productCode This property is required. String
The product code.
productType This property is required. String
The product type.
subscriptionType This property is required. String
Subscription type. Value:

  • Subscription: Prepaid.
  • PayAsYouGo: postpaid.
unit This property is required. String
Attribute unit.
values This property is required. List<Property Map>
Property.

GetOpenApiPricingModulesModuleValue

Name This property is required. string
The module Code corresponds to the attribute value.
Remark This property is required. string
Module value description information.
Type This property is required. string
The attribute value type corresponding to the module Code. Value:

  • single_float: single value type.
  • range_float: range value type.
Value This property is required. string

The module Code corresponds to the attribute value.

format 1024-1024000 when Type = range_float: 1024 means from 1024 to 1024000, step size 1024.

Name This property is required. string
The module Code corresponds to the attribute value.
Remark This property is required. string
Module value description information.
Type This property is required. string
The attribute value type corresponding to the module Code. Value:

  • single_float: single value type.
  • range_float: range value type.
Value This property is required. string

The module Code corresponds to the attribute value.

format 1024-1024000 when Type = range_float: 1024 means from 1024 to 1024000, step size 1024.

name This property is required. String
The module Code corresponds to the attribute value.
remark This property is required. String
Module value description information.
type This property is required. String
The attribute value type corresponding to the module Code. Value:

  • single_float: single value type.
  • range_float: range value type.
value This property is required. String

The module Code corresponds to the attribute value.

format 1024-1024000 when Type = range_float: 1024 means from 1024 to 1024000, step size 1024.

name This property is required. string
The module Code corresponds to the attribute value.
remark This property is required. string
Module value description information.
type This property is required. string
The attribute value type corresponding to the module Code. Value:

  • single_float: single value type.
  • range_float: range value type.
value This property is required. string

The module Code corresponds to the attribute value.

format 1024-1024000 when Type = range_float: 1024 means from 1024 to 1024000, step size 1024.

name This property is required. str
The module Code corresponds to the attribute value.
remark This property is required. str
Module value description information.
type This property is required. str
The attribute value type corresponding to the module Code. Value:

  • single_float: single value type.
  • range_float: range value type.
value This property is required. str

The module Code corresponds to the attribute value.

format 1024-1024000 when Type = range_float: 1024 means from 1024 to 1024000, step size 1024.

name This property is required. String
The module Code corresponds to the attribute value.
remark This property is required. String
Module value description information.
type This property is required. String
The attribute value type corresponding to the module Code. Value:

  • single_float: single value type.
  • range_float: range value type.
value This property is required. String

The module Code corresponds to the attribute value.

format 1024-1024000 when Type = range_float: 1024 means from 1024 to 1024000, step size 1024.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.