Alibaba Cloud v3.62.1 published on Monday, Sep 16, 2024 by Pulumi
alicloud.oos.getStateConfigurations
Explore with Pulumi AI
This data source provides the Oos State Configurations of the current Alibaba Cloud user.
NOTE: Available in v1.147.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.oos.getStateConfigurations({});
export const oosStateConfigurationId1 = ids.then(ids => ids.configurations?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.oos.get_state_configurations()
pulumi.export("oosStateConfigurationId1", ids.configurations[0].id)
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.GetStateConfigurations(ctx, nil, nil)
if err != nil {
return err
}
ctx.Export("oosStateConfigurationId1", ids.Configurations[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Oos.GetStateConfigurations.Invoke();
return new Dictionary<string, object?>
{
["oosStateConfigurationId1"] = ids.Apply(getStateConfigurationsResult => getStateConfigurationsResult.Configurations[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.oos.OosFunctions;
import com.pulumi.alicloud.oos.inputs.GetStateConfigurationsArgs;
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 ids = OosFunctions.getStateConfigurations();
ctx.export("oosStateConfigurationId1", ids.applyValue(getStateConfigurationsResult -> getStateConfigurationsResult.configurations()[0].id()));
}
}
variables:
ids:
fn::invoke:
Function: alicloud:oos:getStateConfigurations
Arguments: {}
outputs:
oosStateConfigurationId1: ${ids.configurations[0].id}
Using getStateConfigurations
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 getStateConfigurations(args: GetStateConfigurationsArgs, opts?: InvokeOptions): Promise<GetStateConfigurationsResult>
function getStateConfigurationsOutput(args: GetStateConfigurationsOutputArgs, opts?: InvokeOptions): Output<GetStateConfigurationsResult>
def get_state_configurations(ids: Optional[Sequence[str]] = None,
output_file: Optional[str] = None,
resource_group_id: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
opts: Optional[InvokeOptions] = None) -> GetStateConfigurationsResult
def get_state_configurations_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
output_file: Optional[pulumi.Input[str]] = None,
resource_group_id: Optional[pulumi.Input[str]] = None,
tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetStateConfigurationsResult]
func GetStateConfigurations(ctx *Context, args *GetStateConfigurationsArgs, opts ...InvokeOption) (*GetStateConfigurationsResult, error)
func GetStateConfigurationsOutput(ctx *Context, args *GetStateConfigurationsOutputArgs, opts ...InvokeOption) GetStateConfigurationsResultOutput
> Note: This function is named GetStateConfigurations
in the Go SDK.
public static class GetStateConfigurations
{
public static Task<GetStateConfigurationsResult> InvokeAsync(GetStateConfigurationsArgs args, InvokeOptions? opts = null)
public static Output<GetStateConfigurationsResult> Invoke(GetStateConfigurationsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetStateConfigurationsResult> getStateConfigurations(GetStateConfigurationsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:oos/getStateConfigurations:getStateConfigurations
arguments:
# arguments dictionary
The following arguments are supported:
- Ids List<string>
- A list of State Configuration IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Resource
Group stringId - The ID of the resource group.
- Dictionary<string, string>
- The tag of the resource.
- Ids []string
- A list of State Configuration IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Resource
Group stringId - The ID of the resource group.
- map[string]string
- The tag of the resource.
- ids List<String>
- A list of State Configuration IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - resource
Group StringId - The ID of the resource group.
- Map<String,String>
- The tag of the resource.
- ids string[]
- A list of State Configuration IDs.
- output
File string - File name where to save data source results (after running
pulumi preview
). - resource
Group stringId - The ID of the resource group.
- {[key: string]: string}
- The tag of the resource.
- ids Sequence[str]
- A list of State Configuration IDs.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - resource_
group_ strid - The ID of the resource group.
- Mapping[str, str]
- The tag of the resource.
- ids List<String>
- A list of State Configuration IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - resource
Group StringId - The ID of the resource group.
- Map<String>
- The tag of the resource.
getStateConfigurations Result
The following output properties are available:
- Configurations
List<Pulumi.
Ali Cloud. Oos. Outputs. Get State Configurations Configuration> - Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Output
File string - Resource
Group stringId - Dictionary<string, string>
- Configurations
[]Get
State Configurations Configuration - Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Output
File string - Resource
Group stringId - map[string]string
- configurations
List<Get
State Configurations Configuration> - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- output
File String - resource
Group StringId - Map<String,String>
- configurations
Get
State Configurations Configuration[] - id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- output
File string - resource
Group stringId - {[key: string]: string}
- configurations
Sequence[Get
State Configurations Configuration] - id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- output_
file str - resource_
group_ strid - Mapping[str, str]
- configurations List<Property Map>
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- output
File String - resource
Group StringId - Map<String>
Supporting Types
GetStateConfigurationsConfiguration
- Configure
Mode string - The configuration mode.
- Create
Time string - The creation time.
- Description string
- The description.
- Id string
- The ID of the State Configuration.
- Parameters string
- The parameters.
- Resource
Group stringId - The ID of the resource group.
- Schedule
Expression string - The schedule expression.
- Schedule
Type string - The schedule type.
- State
Configuration stringId - The ID of the final state configuration.
- Dictionary<string, string>
- The tag of the resource.
- Targets string
- The target resource.
- Template
Id string - The ID of the template.
- Template
Name string - The name of the template.
- Template
Version string - The version of the template.
- Update
Time string - The time when the configuration is updated.
- Configure
Mode string - The configuration mode.
- Create
Time string - The creation time.
- Description string
- The description.
- Id string
- The ID of the State Configuration.
- Parameters string
- The parameters.
- Resource
Group stringId - The ID of the resource group.
- Schedule
Expression string - The schedule expression.
- Schedule
Type string - The schedule type.
- State
Configuration stringId - The ID of the final state configuration.
- map[string]string
- The tag of the resource.
- Targets string
- The target resource.
- Template
Id string - The ID of the template.
- Template
Name string - The name of the template.
- Template
Version string - The version of the template.
- Update
Time string - The time when the configuration is updated.
- configure
Mode String - The configuration mode.
- create
Time String - The creation time.
- description String
- The description.
- id String
- The ID of the State Configuration.
- parameters String
- The parameters.
- resource
Group StringId - The ID of the resource group.
- schedule
Expression String - The schedule expression.
- schedule
Type String - The schedule type.
- state
Configuration StringId - The ID of the final state configuration.
- Map<String,String>
- The tag of the resource.
- targets String
- The target resource.
- template
Id String - The ID of the template.
- template
Name String - The name of the template.
- template
Version String - The version of the template.
- update
Time String - The time when the configuration is updated.
- configure
Mode string - The configuration mode.
- create
Time string - The creation time.
- description string
- The description.
- id string
- The ID of the State Configuration.
- parameters string
- The parameters.
- resource
Group stringId - The ID of the resource group.
- schedule
Expression string - The schedule expression.
- schedule
Type string - The schedule type.
- state
Configuration stringId - The ID of the final state configuration.
- {[key: string]: string}
- The tag of the resource.
- targets string
- The target resource.
- template
Id string - The ID of the template.
- template
Name string - The name of the template.
- template
Version string - The version of the template.
- update
Time string - The time when the configuration is updated.
- configure_
mode str - The configuration mode.
- create_
time str - The creation time.
- description str
- The description.
- id str
- The ID of the State Configuration.
- parameters str
- The parameters.
- resource_
group_ strid - The ID of the resource group.
- schedule_
expression str - The schedule expression.
- schedule_
type str - The schedule type.
- state_
configuration_ strid - The ID of the final state configuration.
- Mapping[str, str]
- The tag of the resource.
- targets str
- The target resource.
- template_
id str - The ID of the template.
- template_
name str - The name of the template.
- template_
version str - The version of the template.
- update_
time str - The time when the configuration is updated.
- configure
Mode String - The configuration mode.
- create
Time String - The creation time.
- description String
- The description.
- id String
- The ID of the State Configuration.
- parameters String
- The parameters.
- resource
Group StringId - The ID of the resource group.
- schedule
Expression String - The schedule expression.
- schedule
Type String - The schedule type.
- state
Configuration StringId - The ID of the final state configuration.
- Map<String>
- The tag of the resource.
- targets String
- The target resource.
- template
Id String - The ID of the template.
- template
Name String - The name of the template.
- template
Version String - The version of the template.
- update
Time String - The time when the configuration is updated.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.