1. Packages
  2. Packages
  3. OVH
  4. API Docs
  5. getCloudStorageBlockVolumes
Viewing docs for OVHCloud v2.14.0
published on Monday, Jun 15, 2026 by OVHcloud
ovh logo
Viewing docs for OVHCloud v2.14.0
published on Monday, Jun 15, 2026 by OVHcloud

    List the block storage volumes of a region in a public cloud project.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@ovhcloud/pulumi-ovh";
    
    const volumes = ovh.getCloudStorageBlockVolumes({
        serviceName: "xxxxxxxxx",
        region: "GRA9",
    });
    
    import pulumi
    import pulumi_ovh as ovh
    
    volumes = ovh.get_cloud_storage_block_volumes(service_name="xxxxxxxxx",
        region="GRA9")
    
    package main
    
    import (
    	"github.com/ovh/pulumi-ovh/sdk/v2/go/ovh"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ovh.GetCloudStorageBlockVolumes(ctx, &ovh.GetCloudStorageBlockVolumesArgs{
    			ServiceName: "xxxxxxxxx",
    			Region:      "GRA9",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var volumes = Ovh.GetCloudStorageBlockVolumes.Invoke(new()
        {
            ServiceName = "xxxxxxxxx",
            Region = "GRA9",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ovh.OvhFunctions;
    import com.pulumi.ovh.inputs.GetCloudStorageBlockVolumesArgs;
    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 volumes = OvhFunctions.getCloudStorageBlockVolumes(GetCloudStorageBlockVolumesArgs.builder()
                .serviceName("xxxxxxxxx")
                .region("GRA9")
                .build());
    
        }
    }
    
    variables:
      volumes:
        fn::invoke:
          function: ovh:getCloudStorageBlockVolumes
          arguments:
            serviceName: xxxxxxxxx
            region: GRA9
    
    Example coming soon!
    

    Using getCloudStorageBlockVolumes

    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 getCloudStorageBlockVolumes(args: GetCloudStorageBlockVolumesArgs, opts?: InvokeOptions): Promise<GetCloudStorageBlockVolumesResult>
    function getCloudStorageBlockVolumesOutput(args: GetCloudStorageBlockVolumesOutputArgs, opts?: InvokeOptions): Output<GetCloudStorageBlockVolumesResult>
    def get_cloud_storage_block_volumes(region: Optional[str] = None,
                                        service_name: Optional[str] = None,
                                        opts: Optional[InvokeOptions] = None) -> GetCloudStorageBlockVolumesResult
    def get_cloud_storage_block_volumes_output(region: pulumi.Input[Optional[str]] = None,
                                        service_name: pulumi.Input[Optional[str]] = None,
                                        opts: Optional[InvokeOptions] = None) -> Output[GetCloudStorageBlockVolumesResult]
    func GetCloudStorageBlockVolumes(ctx *Context, args *GetCloudStorageBlockVolumesArgs, opts ...InvokeOption) (*GetCloudStorageBlockVolumesResult, error)
    func GetCloudStorageBlockVolumesOutput(ctx *Context, args *GetCloudStorageBlockVolumesOutputArgs, opts ...InvokeOption) GetCloudStorageBlockVolumesResultOutput

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

    public static class GetCloudStorageBlockVolumes 
    {
        public static Task<GetCloudStorageBlockVolumesResult> InvokeAsync(GetCloudStorageBlockVolumesArgs args, InvokeOptions? opts = null)
        public static Output<GetCloudStorageBlockVolumesResult> Invoke(GetCloudStorageBlockVolumesInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetCloudStorageBlockVolumesResult> getCloudStorageBlockVolumes(GetCloudStorageBlockVolumesArgs args, InvokeOptions options)
    public static Output<GetCloudStorageBlockVolumesResult> getCloudStorageBlockVolumes(GetCloudStorageBlockVolumesArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ovh:index/getCloudStorageBlockVolumes:getCloudStorageBlockVolumes
      arguments:
        # arguments dictionary
    data "ovh_getcloudstorageblockvolumes" "name" {
        # arguments
    }

    The following arguments are supported:

    Region string
    The region where the volumes reside.
    ServiceName string
    The id of the public cloud project.
    Region string
    The region where the volumes reside.
    ServiceName string
    The id of the public cloud project.
    region string
    The region where the volumes reside.
    service_name string
    The id of the public cloud project.
    region String
    The region where the volumes reside.
    serviceName String
    The id of the public cloud project.
    region string
    The region where the volumes reside.
    serviceName string
    The id of the public cloud project.
    region str
    The region where the volumes reside.
    service_name str
    The id of the public cloud project.
    region String
    The region where the volumes reside.
    serviceName String
    The id of the public cloud project.

    getCloudStorageBlockVolumes Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Region string
    Region.
    ServiceName string
    Volumes List<GetCloudStorageBlockVolumesVolume>
    List of volumes:
    Id string
    The provider-assigned unique ID for this managed resource.
    Region string
    Region.
    ServiceName string
    Volumes []GetCloudStorageBlockVolumesVolume
    List of volumes:
    id string
    The provider-assigned unique ID for this managed resource.
    region string
    Region.
    service_name string
    volumes list(object)
    List of volumes:
    id String
    The provider-assigned unique ID for this managed resource.
    region String
    Region.
    serviceName String
    volumes List<GetCloudStorageBlockVolumesVolume>
    List of volumes:
    id string
    The provider-assigned unique ID for this managed resource.
    region string
    Region.
    serviceName string
    volumes GetCloudStorageBlockVolumesVolume[]
    List of volumes:
    id str
    The provider-assigned unique ID for this managed resource.
    region str
    Region.
    service_name str
    volumes Sequence[GetCloudStorageBlockVolumesVolume]
    List of volumes:
    id String
    The provider-assigned unique ID for this managed resource.
    region String
    Region.
    serviceName String
    volumes List<Property Map>
    List of volumes:

    Supporting Types

    GetCloudStorageBlockVolumesVolume

    AttachedInstances List<GetCloudStorageBlockVolumesVolumeAttachedInstance>
    Instances the volume is attached to:
    Bootable bool
    Whether the volume is bootable.
    Encryption GetCloudStorageBlockVolumesVolumeEncryption
    Encryption configuration of the volume:
    Id string
    Instance ID.
    Location GetCloudStorageBlockVolumesVolumeLocation
    Location of the volume:
    Name string
    Volume name.
    ResourceStatus string
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    Size int
    Size of the volume in GB.
    Status string
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    VolumeType string
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).
    AttachedInstances []GetCloudStorageBlockVolumesVolumeAttachedInstance
    Instances the volume is attached to:
    Bootable bool
    Whether the volume is bootable.
    Encryption GetCloudStorageBlockVolumesVolumeEncryption
    Encryption configuration of the volume:
    Id string
    Instance ID.
    Location GetCloudStorageBlockVolumesVolumeLocation
    Location of the volume:
    Name string
    Volume name.
    ResourceStatus string
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    Size int
    Size of the volume in GB.
    Status string
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    VolumeType string
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).
    attached_instances list(object)
    Instances the volume is attached to:
    bootable bool
    Whether the volume is bootable.
    encryption object
    Encryption configuration of the volume:
    id string
    Instance ID.
    location object
    Location of the volume:
    name string
    Volume name.
    resource_status string
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    size number
    Size of the volume in GB.
    status string
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    volume_type string
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).
    attachedInstances List<GetCloudStorageBlockVolumesVolumeAttachedInstance>
    Instances the volume is attached to:
    bootable Boolean
    Whether the volume is bootable.
    encryption GetCloudStorageBlockVolumesVolumeEncryption
    Encryption configuration of the volume:
    id String
    Instance ID.
    location GetCloudStorageBlockVolumesVolumeLocation
    Location of the volume:
    name String
    Volume name.
    resourceStatus String
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    size Integer
    Size of the volume in GB.
    status String
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    volumeType String
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).
    attachedInstances GetCloudStorageBlockVolumesVolumeAttachedInstance[]
    Instances the volume is attached to:
    bootable boolean
    Whether the volume is bootable.
    encryption GetCloudStorageBlockVolumesVolumeEncryption
    Encryption configuration of the volume:
    id string
    Instance ID.
    location GetCloudStorageBlockVolumesVolumeLocation
    Location of the volume:
    name string
    Volume name.
    resourceStatus string
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    size number
    Size of the volume in GB.
    status string
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    volumeType string
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).
    attached_instances Sequence[GetCloudStorageBlockVolumesVolumeAttachedInstance]
    Instances the volume is attached to:
    bootable bool
    Whether the volume is bootable.
    encryption GetCloudStorageBlockVolumesVolumeEncryption
    Encryption configuration of the volume:
    id str
    Instance ID.
    location GetCloudStorageBlockVolumesVolumeLocation
    Location of the volume:
    name str
    Volume name.
    resource_status str
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    size int
    Size of the volume in GB.
    status str
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    volume_type str
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).
    attachedInstances List<Property Map>
    Instances the volume is attached to:
    bootable Boolean
    Whether the volume is bootable.
    encryption Property Map
    Encryption configuration of the volume:
    id String
    Instance ID.
    location Property Map
    Location of the volume:
    name String
    Volume name.
    resourceStatus String
    Volume readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY, UPDATING).
    size Number
    Size of the volume in GB.
    status String
    Volume status (AVAILABLE, IN_USE, CREATING, DELETING, ATTACHING, DETACHING, EXTENDING, ERROR, ERROR_DELETING, ERROR_BACKING_UP, ERROR_RESTORING, ERROR_EXTENDING).
    volumeType String
    Volume type (CLASSIC, HIGH_SPEED, HIGH_SPEED_GEN2).

    GetCloudStorageBlockVolumesVolumeAttachedInstance

    Id string
    Instance ID.
    Id string
    Instance ID.
    id string
    Instance ID.
    id String
    Instance ID.
    id string
    Instance ID.
    id str
    Instance ID.
    id String
    Instance ID.

    GetCloudStorageBlockVolumesVolumeEncryption

    Enabled bool
    Whether the volume is encrypted at rest with LUKS.
    Enabled bool
    Whether the volume is encrypted at rest with LUKS.
    enabled bool
    Whether the volume is encrypted at rest with LUKS.
    enabled Boolean
    Whether the volume is encrypted at rest with LUKS.
    enabled boolean
    Whether the volume is encrypted at rest with LUKS.
    enabled bool
    Whether the volume is encrypted at rest with LUKS.
    enabled Boolean
    Whether the volume is encrypted at rest with LUKS.

    GetCloudStorageBlockVolumesVolumeLocation

    Region string
    The region where the volumes reside.
    Region string
    The region where the volumes reside.
    region string
    The region where the volumes reside.
    region String
    The region where the volumes reside.
    region string
    The region where the volumes reside.
    region str
    The region where the volumes reside.
    region String
    The region where the volumes reside.

    Package Details

    Repository
    ovh ovh/pulumi-ovh
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ovh Terraform Provider.
    ovh logo
    Viewing docs for OVHCloud v2.14.0
    published on Monday, Jun 15, 2026 by OVHcloud

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial