1. Packages
  2. Alicloud Provider
  3. API Docs
  4. hbr
  5. getReplicationVaultRegions
Alibaba Cloud v3.62.1 published on Monday, Sep 16, 2024 by Pulumi

alicloud.hbr.getReplicationVaultRegions

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.62.1 published on Monday, Sep 16, 2024 by Pulumi

    This data source provides the HBR Replication Vault Regions of the current Alibaba Cloud user.

    NOTE: Available in v1.152.0+.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const default = alicloud.hbr.getReplicationVaultRegions({});
    export const hbrReplicationVaultRegionRegionId1 = _default.then(_default => _default.regions?.[0]?.replicationRegionId);
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    default = alicloud.hbr.get_replication_vault_regions()
    pulumi.export("hbrReplicationVaultRegionRegionId1", default.regions[0].replication_region_id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/hbr"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_default, err := hbr.GetReplicationVaultRegions(ctx, nil, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("hbrReplicationVaultRegionRegionId1", _default.Regions[0].ReplicationRegionId)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var @default = AliCloud.Hbr.GetReplicationVaultRegions.Invoke();
    
        return new Dictionary<string, object?>
        {
            ["hbrReplicationVaultRegionRegionId1"] = @default.Apply(@default => @default.Apply(getReplicationVaultRegionsResult => getReplicationVaultRegionsResult.Regions[0]?.ReplicationRegionId)),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.hbr.HbrFunctions;
    import com.pulumi.alicloud.hbr.inputs.GetReplicationVaultRegionsArgs;
    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 = HbrFunctions.getReplicationVaultRegions();
    
            ctx.export("hbrReplicationVaultRegionRegionId1", default_.regions()[0].replicationRegionId());
        }
    }
    
    variables:
      default:
        fn::invoke:
          Function: alicloud:hbr:getReplicationVaultRegions
          Arguments: {}
    outputs:
      hbrReplicationVaultRegionRegionId1: ${default.regions[0].replicationRegionId}
    

    Using getReplicationVaultRegions

    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 getReplicationVaultRegions(args: GetReplicationVaultRegionsArgs, opts?: InvokeOptions): Promise<GetReplicationVaultRegionsResult>
    function getReplicationVaultRegionsOutput(args: GetReplicationVaultRegionsOutputArgs, opts?: InvokeOptions): Output<GetReplicationVaultRegionsResult>
    def get_replication_vault_regions(output_file: Optional[str] = None,
                                      opts: Optional[InvokeOptions] = None) -> GetReplicationVaultRegionsResult
    def get_replication_vault_regions_output(output_file: Optional[pulumi.Input[str]] = None,
                                      opts: Optional[InvokeOptions] = None) -> Output[GetReplicationVaultRegionsResult]
    func GetReplicationVaultRegions(ctx *Context, args *GetReplicationVaultRegionsArgs, opts ...InvokeOption) (*GetReplicationVaultRegionsResult, error)
    func GetReplicationVaultRegionsOutput(ctx *Context, args *GetReplicationVaultRegionsOutputArgs, opts ...InvokeOption) GetReplicationVaultRegionsResultOutput

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

    public static class GetReplicationVaultRegions 
    {
        public static Task<GetReplicationVaultRegionsResult> InvokeAsync(GetReplicationVaultRegionsArgs args, InvokeOptions? opts = null)
        public static Output<GetReplicationVaultRegionsResult> Invoke(GetReplicationVaultRegionsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetReplicationVaultRegionsResult> getReplicationVaultRegions(GetReplicationVaultRegionsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: alicloud:hbr/getReplicationVaultRegions:getReplicationVaultRegions
      arguments:
        # arguments dictionary

    The following arguments are supported:

    OutputFile string
    File name where to save data source results (after running pulumi preview).
    OutputFile string
    File name where to save data source results (after running pulumi preview).
    outputFile String
    File name where to save data source results (after running pulumi preview).
    outputFile string
    File name where to save data source results (after running pulumi preview).
    output_file str
    File name where to save data source results (after running pulumi preview).
    outputFile String
    File name where to save data source results (after running pulumi preview).

    getReplicationVaultRegions Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Regions List<Pulumi.AliCloud.Hbr.Outputs.GetReplicationVaultRegionsRegion>
    OutputFile string
    Id string
    The provider-assigned unique ID for this managed resource.
    Regions []GetReplicationVaultRegionsRegion
    OutputFile string
    id String
    The provider-assigned unique ID for this managed resource.
    regions List<GetReplicationVaultRegionsRegion>
    outputFile String
    id string
    The provider-assigned unique ID for this managed resource.
    regions GetReplicationVaultRegionsRegion[]
    outputFile string
    id str
    The provider-assigned unique ID for this managed resource.
    regions Sequence[GetReplicationVaultRegionsRegion]
    output_file str
    id String
    The provider-assigned unique ID for this managed resource.
    regions List<Property Map>
    outputFile String

    Supporting Types

    GetReplicationVaultRegionsRegion

    ReplicationRegionId string
    The ID of the replication region.
    ReplicationRegionId string
    The ID of the replication region.
    replicationRegionId String
    The ID of the replication region.
    replicationRegionId string
    The ID of the replication region.
    replication_region_id str
    The ID of the replication region.
    replicationRegionId String
    The ID of the replication region.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.62.1 published on Monday, Sep 16, 2024 by Pulumi