Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.26.0 published on Friday, Jul 29, 2022 by Pulumi

getParameters

This data source provides the Oos Parameters of the current Alibaba Cloud user.

NOTE: Available in v1.147.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var ids = Output.Create(AliCloud.Oos.GetParameters.InvokeAsync(new AliCloud.Oos.GetParametersArgs
        {
            Ids = 
            {
                "my-Parameter",
            },
        }));
        this.OosParameterId1 = ids.Apply(ids => ids.Parameters?[0]?.Id);
        var nameRegex = Output.Create(AliCloud.Oos.GetParameters.InvokeAsync(new AliCloud.Oos.GetParametersArgs
        {
            NameRegex = "^my-Parameter",
        }));
        this.OosParameterId2 = nameRegex.Apply(nameRegex => nameRegex.Parameters?[0]?.Id);
        var resourceGroupId = Output.Create(AliCloud.Oos.GetParameters.InvokeAsync(new AliCloud.Oos.GetParametersArgs
        {
            Ids = 
            {
                "my-Parameter",
            },
            ResourceGroupId = "example_value",
        }));
        this.OosParameterId3 = resourceGroupId.Apply(resourceGroupId => resourceGroupId.Parameters?[0]?.Id);
        var tags = Output.Create(AliCloud.Oos.GetParameters.InvokeAsync(new AliCloud.Oos.GetParametersArgs
        {
            Ids = 
            {
                "my-Parameter",
            },
            Tags = 
            {
                { "Created", "TF" },
                { "For", "OosParameter" },
            },
        }));
        this.OosParameterId4 = tags.Apply(tags => tags.Parameters?[0]?.Id);
    }

    [Output("oosParameterId1")]
    public Output<string> OosParameterId1 { get; set; }
    [Output("oosParameterId2")]
    public Output<string> OosParameterId2 { get; set; }
    [Output("oosParameterId3")]
    public Output<string> OosParameterId3 { get; set; }
    [Output("oosParameterId4")]
    public Output<string> OosParameterId4 { get; set; }
}
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ids, err := oos.GetParameters(ctx, &oos.GetParametersArgs{
			Ids: []string{
				"my-Parameter",
			},
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("oosParameterId1", ids.Parameters[0].Id)
		nameRegex, err := oos.GetParameters(ctx, &oos.GetParametersArgs{
			NameRegex: pulumi.StringRef("^my-Parameter"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("oosParameterId2", nameRegex.Parameters[0].Id)
		resourceGroupId, err := oos.GetParameters(ctx, &oos.GetParametersArgs{
			Ids: []string{
				"my-Parameter",
			},
			ResourceGroupId: pulumi.StringRef("example_value"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("oosParameterId3", resourceGroupId.Parameters[0].Id)
		tags, err := oos.GetParameters(ctx, &oos.GetParametersArgs{
			Ids: []string{
				"my-Parameter",
			},
			Tags: map[string]interface{}{
				"Created": "TF",
				"For":     "OosParameter",
			},
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("oosParameterId4", tags.Parameters[0].Id)
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

ids = alicloud.oos.get_parameters(ids=["my-Parameter"])
pulumi.export("oosParameterId1", ids.parameters[0].id)
name_regex = alicloud.oos.get_parameters(name_regex="^my-Parameter")
pulumi.export("oosParameterId2", name_regex.parameters[0].id)
resource_group_id = alicloud.oos.get_parameters(ids=["my-Parameter"],
    resource_group_id="example_value")
pulumi.export("oosParameterId3", resource_group_id.parameters[0].id)
tags = alicloud.oos.get_parameters(ids=["my-Parameter"],
    tags={
        "Created": "TF",
        "For": "OosParameter",
    })
pulumi.export("oosParameterId4", tags.parameters[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const ids = alicloud.oos.getParameters({
    ids: ["my-Parameter"],
});
export const oosParameterId1 = ids.then(ids => ids.parameters?[0]?.id);
const nameRegex = alicloud.oos.getParameters({
    nameRegex: "^my-Parameter",
});
export const oosParameterId2 = nameRegex.then(nameRegex => nameRegex.parameters?[0]?.id);
const resourceGroupId = alicloud.oos.getParameters({
    ids: ["my-Parameter"],
    resourceGroupId: "example_value",
});
export const oosParameterId3 = resourceGroupId.then(resourceGroupId => resourceGroupId.parameters?[0]?.id);
const tags = alicloud.oos.getParameters({
    ids: ["my-Parameter"],
    tags: {
        Created: "TF",
        For: "OosParameter",
    },
});
export const oosParameterId4 = tags.then(tags => tags.parameters?[0]?.id);

Coming soon!

Using getParameters

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 getParameters(args: GetParametersArgs, opts?: InvokeOptions): Promise<GetParametersResult>
function getParametersOutput(args: GetParametersOutputArgs, opts?: InvokeOptions): Output<GetParametersResult>
def get_parameters(enable_details: Optional[bool] = None,
                   ids: Optional[Sequence[str]] = None,
                   name_regex: Optional[str] = None,
                   output_file: Optional[str] = None,
                   parameter_name: Optional[str] = None,
                   resource_group_id: Optional[str] = None,
                   sort_field: Optional[str] = None,
                   sort_order: Optional[str] = None,
                   tags: Optional[Mapping[str, Any]] = None,
                   type: Optional[str] = None,
                   opts: Optional[InvokeOptions] = None) -> GetParametersResult
def get_parameters_output(enable_details: Optional[pulumi.Input[bool]] = None,
                   ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                   name_regex: Optional[pulumi.Input[str]] = None,
                   output_file: Optional[pulumi.Input[str]] = None,
                   parameter_name: Optional[pulumi.Input[str]] = None,
                   resource_group_id: Optional[pulumi.Input[str]] = None,
                   sort_field: Optional[pulumi.Input[str]] = None,
                   sort_order: Optional[pulumi.Input[str]] = None,
                   tags: Optional[pulumi.Input[Mapping[str, Any]]] = None,
                   type: Optional[pulumi.Input[str]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetParametersResult]
func GetParameters(ctx *Context, args *GetParametersArgs, opts ...InvokeOption) (*GetParametersResult, error)
func GetParametersOutput(ctx *Context, args *GetParametersOutputArgs, opts ...InvokeOption) GetParametersResultOutput

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

public static class GetParameters 
{
    public static Task<GetParametersResult> InvokeAsync(GetParametersArgs args, InvokeOptions? opts = null)
    public static Output<GetParametersResult> Invoke(GetParametersInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetParametersResult> getParameters(GetParametersArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: alicloud:oos/getParameters:getParameters
  Arguments:
    # Arguments dictionary

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 Parameter IDs. Its element value is same as Parameter Name.

NameRegex string

A regex string to filter results by Parameter name.

OutputFile string
ParameterName string

The name of the common parameter.

ResourceGroupId string

The ID of the Resource Group.

SortField string
SortOrder string
Tags Dictionary<string, object>

The tag of the resource.

Type string

The data type of the common parameter.

EnableDetails bool

Default to false. Set it to true can output more details about resource attributes.

Ids []string

A list of Parameter IDs. Its element value is same as Parameter Name.

NameRegex string

A regex string to filter results by Parameter name.

OutputFile string
ParameterName string

The name of the common parameter.

ResourceGroupId string

The ID of the Resource Group.

SortField string
SortOrder string
Tags map[string]interface{}

The tag of the resource.

Type string

The data type of the common parameter.

enableDetails Boolean

Default to false. Set it to true can output more details about resource attributes.

ids List<String>

A list of Parameter IDs. Its element value is same as Parameter Name.

nameRegex String

A regex string to filter results by Parameter name.

outputFile String
parameterName String

The name of the common parameter.

resourceGroupId String

The ID of the Resource Group.

sortField String
sortOrder String
tags Map<String,Object>

The tag of the resource.

type String

The data type of the common parameter.

enableDetails boolean

Default to false. Set it to true can output more details about resource attributes.

ids string[]

A list of Parameter IDs. Its element value is same as Parameter Name.

nameRegex string

A regex string to filter results by Parameter name.

outputFile string
parameterName string

The name of the common parameter.

resourceGroupId string

The ID of the Resource Group.

sortField string
sortOrder string
tags {[key: string]: any}

The tag of the resource.

type string

The data type of the common parameter.

enable_details bool

Default to false. Set it to true can output more details about resource attributes.

ids Sequence[str]

A list of Parameter IDs. Its element value is same as Parameter Name.

name_regex str

A regex string to filter results by Parameter name.

output_file str
parameter_name str

The name of the common parameter.

resource_group_id str

The ID of the Resource Group.

sort_field str
sort_order str
tags Mapping[str, Any]

The tag of the resource.

type str

The data type of the common parameter.

enableDetails Boolean

Default to false. Set it to true can output more details about resource attributes.

ids List<String>

A list of Parameter IDs. Its element value is same as Parameter Name.

nameRegex String

A regex string to filter results by Parameter name.

outputFile String
parameterName String

The name of the common parameter.

resourceGroupId String

The ID of the Resource Group.

sortField String
sortOrder String
tags Map<Any>

The tag of the resource.

type String

The data type of the common parameter.

getParameters Result

The following output properties are available:

Id string

The provider-assigned unique ID for this managed resource.

Ids List<string>
Names List<string>
Parameters List<Pulumi.AliCloud.Oos.Outputs.GetParametersParameter>
EnableDetails bool
NameRegex string
OutputFile string
ParameterName string
ResourceGroupId string
SortField string
SortOrder string
Tags Dictionary<string, object>
Type string
Id string

The provider-assigned unique ID for this managed resource.

Ids []string
Names []string
Parameters []GetParametersParameter
EnableDetails bool
NameRegex string
OutputFile string
ParameterName string
ResourceGroupId string
SortField string
SortOrder string
Tags map[string]interface{}
Type string
id String

The provider-assigned unique ID for this managed resource.

ids List<String>
names List<String>
parameters List<GetParametersParameter>
enableDetails Boolean
nameRegex String
outputFile String
parameterName String
resourceGroupId String
sortField String
sortOrder String
tags Map<String,Object>
type String
id string

The provider-assigned unique ID for this managed resource.

ids string[]
names string[]
parameters GetParametersParameter[]
enableDetails boolean
nameRegex string
outputFile string
parameterName string
resourceGroupId string
sortField string
sortOrder string
tags {[key: string]: any}
type string
id str

The provider-assigned unique ID for this managed resource.

ids Sequence[str]
names Sequence[str]
parameters Sequence[GetParametersParameter]
enable_details bool
name_regex str
output_file str
parameter_name str
resource_group_id str
sort_field str
sort_order str
tags Mapping[str, Any]
type str
id String

The provider-assigned unique ID for this managed resource.

ids List<String>
names List<String>
parameters List<Property Map>
enableDetails Boolean
nameRegex String
outputFile String
parameterName String
resourceGroupId String
sortField String
sortOrder String
tags Map<Any>
type String

Supporting Types

GetParametersParameter

Constraints string

The constraints of the common parameter.

CreateTime string

The time when the common parameter was created.

CreatedBy string

The user who created the common parameter.

Description string

The description of the common parameter.

Id string

The ID of the Parameter. Its value is same as parameter_name.

ParameterId string

The ID of the common parameter.

ParameterName string

The name of the common parameter.

ParameterVersion int

The version number of the common parameter.

ResourceGroupId string

The ID of the Resource Group.

ShareType string

The share type of the common parameter.

Tags Dictionary<string, object>

The tag of the resource.

Type string

The data type of the common parameter.

UpdatedBy string

The user who updated the common parameter.

UpdatedDate string

The time when the common parameter was updated.

Value string

The value of the common parameter.

Constraints string

The constraints of the common parameter.

CreateTime string

The time when the common parameter was created.

CreatedBy string

The user who created the common parameter.

Description string

The description of the common parameter.

Id string

The ID of the Parameter. Its value is same as parameter_name.

ParameterId string

The ID of the common parameter.

ParameterName string

The name of the common parameter.

ParameterVersion int

The version number of the common parameter.

ResourceGroupId string

The ID of the Resource Group.

ShareType string

The share type of the common parameter.

Tags map[string]interface{}

The tag of the resource.

Type string

The data type of the common parameter.

UpdatedBy string

The user who updated the common parameter.

UpdatedDate string

The time when the common parameter was updated.

Value string

The value of the common parameter.

constraints String

The constraints of the common parameter.

createTime String

The time when the common parameter was created.

createdBy String

The user who created the common parameter.

description String

The description of the common parameter.

id String

The ID of the Parameter. Its value is same as parameter_name.

parameterId String

The ID of the common parameter.

parameterName String

The name of the common parameter.

parameterVersion Integer

The version number of the common parameter.

resourceGroupId String

The ID of the Resource Group.

shareType String

The share type of the common parameter.

tags Map<String,Object>

The tag of the resource.

type String

The data type of the common parameter.

updatedBy String

The user who updated the common parameter.

updatedDate String

The time when the common parameter was updated.

value String

The value of the common parameter.

constraints string

The constraints of the common parameter.

createTime string

The time when the common parameter was created.

createdBy string

The user who created the common parameter.

description string

The description of the common parameter.

id string

The ID of the Parameter. Its value is same as parameter_name.

parameterId string

The ID of the common parameter.

parameterName string

The name of the common parameter.

parameterVersion number

The version number of the common parameter.

resourceGroupId string

The ID of the Resource Group.

shareType string

The share type of the common parameter.

tags {[key: string]: any}

The tag of the resource.

type string

The data type of the common parameter.

updatedBy string

The user who updated the common parameter.

updatedDate string

The time when the common parameter was updated.

value string

The value of the common parameter.

constraints str

The constraints of the common parameter.

create_time str

The time when the common parameter was created.

created_by str

The user who created the common parameter.

description str

The description of the common parameter.

id str

The ID of the Parameter. Its value is same as parameter_name.

parameter_id str

The ID of the common parameter.

parameter_name str

The name of the common parameter.

parameter_version int

The version number of the common parameter.

resource_group_id str

The ID of the Resource Group.

share_type str

The share type of the common parameter.

tags Mapping[str, Any]

The tag of the resource.

type str

The data type of the common parameter.

updated_by str

The user who updated the common parameter.

updated_date str

The time when the common parameter was updated.

value str

The value of the common parameter.

constraints String

The constraints of the common parameter.

createTime String

The time when the common parameter was created.

createdBy String

The user who created the common parameter.

description String

The description of the common parameter.

id String

The ID of the Parameter. Its value is same as parameter_name.

parameterId String

The ID of the common parameter.

parameterName String

The name of the common parameter.

parameterVersion Number

The version number of the common parameter.

resourceGroupId String

The ID of the Resource Group.

shareType String

The share type of the common parameter.

tags Map<Any>

The tag of the resource.

type String

The data type of the common parameter.

updatedBy String

The user who updated the common parameter.

updatedDate String

The time when the common parameter was updated.

value String

The value of the common parameter.

Package Details

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

This Pulumi package is based on the alicloud Terraform Provider.