1. Registry
  2. Packages
  3. OVH
  4. API Docs
  5. getCloudInstanceSnapshots
Viewing docs for OVHCloud v2.21.0
published on Friday, Sep 25, 2026 by OVHcloud
ovh logo
Viewing docs for OVHCloud v2.21.0
published on Friday, Sep 25, 2026 by OVHcloud

    Use this data source to list the snapshots of an instance in a public cloud project.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@ovhcloud/pulumi-ovh";
    
    const snapshots = ovh.getCloudInstanceSnapshots({
        serviceName: "<Public cloud project id>",
        region: "GRA11",
        instanceId: "<instance id>",
    });
    export const snapshotIds = snapshots.then(snapshots => .map(snapshot => (snapshot.id)));
    
    import pulumi
    import pulumi_ovh as ovh
    
    snapshots = ovh.get_cloud_instance_snapshots(service_name="<Public cloud project id>",
        region="GRA11",
        instance_id="<instance id>")
    pulumi.export("snapshotIds", [snapshot.id for snapshot in snapshots.snapshots])
    
    Example coming soon!
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var snapshots = Ovh.GetCloudInstanceSnapshots.Invoke(new()
        {
            ServiceName = "<Public cloud project id>",
            Region = "GRA11",
            InstanceId = "<instance id>",
        });
    
        return new Dictionary<string, object?>
        {
            ["snapshotIds"] = .Select(snapshot => 
            {
                return snapshot.Id;
            }).ToList(),
        };
    });
    
    Example coming soon!
    
    Example coming soon!
    
    Example coming soon!
    

    Using getCloudInstanceSnapshots

    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 getCloudInstanceSnapshots(args: GetCloudInstanceSnapshotsArgs, opts?: InvokeOptions): Promise<GetCloudInstanceSnapshotsResult>
    function getCloudInstanceSnapshotsOutput(args: GetCloudInstanceSnapshotsOutputArgs, opts?: InvokeOutputOptions): Output<GetCloudInstanceSnapshotsResult>
    def get_cloud_instance_snapshots(instance_id: Optional[str] = None,
                                     region: Optional[str] = None,
                                     service_name: Optional[str] = None,
                                     opts: Optional[InvokeOptions] = None) -> GetCloudInstanceSnapshotsResult
    def get_cloud_instance_snapshots_output(instance_id: pulumi.Input[Optional[str]] = None,
                                     region: pulumi.Input[Optional[str]] = None,
                                     service_name: pulumi.Input[Optional[str]] = None,
                                     opts: Optional[InvokeOutputOptions] = None) -> Output[GetCloudInstanceSnapshotsResult]
    func GetCloudInstanceSnapshots(ctx *Context, args *GetCloudInstanceSnapshotsArgs, opts ...InvokeOption) (*GetCloudInstanceSnapshotsResult, error)
    func GetCloudInstanceSnapshotsOutput(ctx *Context, args *GetCloudInstanceSnapshotsOutputArgs, opts ...InvokeOption) GetCloudInstanceSnapshotsResultOutput

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

    public static class GetCloudInstanceSnapshots 
    {
        public static Task<GetCloudInstanceSnapshotsResult> InvokeAsync(GetCloudInstanceSnapshotsArgs args, InvokeOptions? opts = null)
        public static Output<GetCloudInstanceSnapshotsResult> Invoke(GetCloudInstanceSnapshotsInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetCloudInstanceSnapshotsResult> Invoke(GetCloudInstanceSnapshotsInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetCloudInstanceSnapshotsResult> getCloudInstanceSnapshots(GetCloudInstanceSnapshotsArgs args, InvokeOptions options)
    public static Output<GetCloudInstanceSnapshotsResult> getCloudInstanceSnapshots(GetCloudInstanceSnapshotsArgs args, InvokeOptions options)
    public static Output<GetCloudInstanceSnapshotsResult> getCloudInstanceSnapshots(GetCloudInstanceSnapshotsArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: ovh:index/getCloudInstanceSnapshots:getCloudInstanceSnapshots
      arguments:
        # arguments dictionary
    data "ovh_get_cloud_instance_snapshots" "name" {
        # arguments
    }

    The following arguments are supported:

    InstanceId string
    ID of the instance whose snapshots to list.
    Region string
    Region where the instance snapshots reside.
    ServiceName string
    Service name of the resource representing the id of the cloud project.
    InstanceId string
    ID of the instance whose snapshots to list.
    Region string
    Region where the instance snapshots reside.
    ServiceName string
    Service name of the resource representing the id of the cloud project.
    instance_id string
    ID of the instance whose snapshots to list.
    region string
    Region where the instance snapshots reside.
    service_name string
    Service name of the resource representing the id of the cloud project.
    instanceId String
    ID of the instance whose snapshots to list.
    region String
    Region where the instance snapshots reside.
    serviceName String
    Service name of the resource representing the id of the cloud project.
    instanceId string
    ID of the instance whose snapshots to list.
    region string
    Region where the instance snapshots reside.
    serviceName string
    Service name of the resource representing the id of the cloud project.
    instance_id str
    ID of the instance whose snapshots to list.
    region str
    Region where the instance snapshots reside.
    service_name str
    Service name of the resource representing the id of the cloud project.
    instanceId String
    ID of the instance whose snapshots to list.
    region String
    Region where the instance snapshots reside.
    serviceName String
    Service name of the resource representing the id of the cloud project.

    getCloudInstanceSnapshots Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    InstanceId string
    ID of the snapshotted instance.
    Region string
    Region.
    ServiceName string
    Snapshots List<GetCloudInstanceSnapshotsSnapshot>
    List of snapshots for the instance:
    Id string
    The provider-assigned unique ID for this managed resource.
    InstanceId string
    ID of the snapshotted instance.
    Region string
    Region.
    ServiceName string
    Snapshots []GetCloudInstanceSnapshotsSnapshot
    List of snapshots for the instance:
    id string
    The provider-assigned unique ID for this managed resource.
    instance_id string
    ID of the snapshotted instance.
    region string
    Region.
    service_name string
    snapshots list(object)
    List of snapshots for the instance:
    id String
    The provider-assigned unique ID for this managed resource.
    instanceId String
    ID of the snapshotted instance.
    region String
    Region.
    serviceName String
    snapshots List<GetCloudInstanceSnapshotsSnapshot>
    List of snapshots for the instance:
    id string
    The provider-assigned unique ID for this managed resource.
    instanceId string
    ID of the snapshotted instance.
    region string
    Region.
    serviceName string
    snapshots GetCloudInstanceSnapshotsSnapshot[]
    List of snapshots for the instance:
    id str
    The provider-assigned unique ID for this managed resource.
    instance_id str
    ID of the snapshotted instance.
    region str
    Region.
    service_name str
    snapshots Sequence[GetCloudInstanceSnapshotsSnapshot]
    List of snapshots for the instance:
    id String
    The provider-assigned unique ID for this managed resource.
    instanceId String
    ID of the snapshotted instance.
    region String
    Region.
    serviceName String
    snapshots List<Property Map>
    List of snapshots for the instance:

    Supporting Types

    GetCloudInstanceSnapshotsSnapshot

    Id string
    Snapshot ID.
    InstanceId string
    ID of the instance whose snapshots to list.
    Location GetCloudInstanceSnapshotsSnapshotLocation
    Location of the snapshot:
    Name string
    Snapshot name.
    ResourceStatus string
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    Size int
    Image size in bytes.
    Status string
    Image status in the backend.
    Visibility string
    Image visibility.
    Id string
    Snapshot ID.
    InstanceId string
    ID of the instance whose snapshots to list.
    Location GetCloudInstanceSnapshotsSnapshotLocation
    Location of the snapshot:
    Name string
    Snapshot name.
    ResourceStatus string
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    Size int
    Image size in bytes.
    Status string
    Image status in the backend.
    Visibility string
    Image visibility.
    id string
    Snapshot ID.
    instance_id string
    ID of the instance whose snapshots to list.
    location object
    Location of the snapshot:
    name string
    Snapshot name.
    resource_status string
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    size number
    Image size in bytes.
    status string
    Image status in the backend.
    visibility string
    Image visibility.
    id String
    Snapshot ID.
    instanceId String
    ID of the instance whose snapshots to list.
    location GetCloudInstanceSnapshotsSnapshotLocation
    Location of the snapshot:
    name String
    Snapshot name.
    resourceStatus String
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    size Integer
    Image size in bytes.
    status String
    Image status in the backend.
    visibility String
    Image visibility.
    id string
    Snapshot ID.
    instanceId string
    ID of the instance whose snapshots to list.
    location GetCloudInstanceSnapshotsSnapshotLocation
    Location of the snapshot:
    name string
    Snapshot name.
    resourceStatus string
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    size number
    Image size in bytes.
    status string
    Image status in the backend.
    visibility string
    Image visibility.
    id str
    Snapshot ID.
    instance_id str
    ID of the instance whose snapshots to list.
    location GetCloudInstanceSnapshotsSnapshotLocation
    Location of the snapshot:
    name str
    Snapshot name.
    resource_status str
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    size int
    Image size in bytes.
    status str
    Image status in the backend.
    visibility str
    Image visibility.
    id String
    Snapshot ID.
    instanceId String
    ID of the instance whose snapshots to list.
    location Property Map
    Location of the snapshot:
    name String
    Snapshot name.
    resourceStatus String
    Snapshot readiness in the system (CREATING, DELETING, ERROR, OUT_OF_SYNC, READY).
    size Number
    Image size in bytes.
    status String
    Image status in the backend.
    visibility String
    Image visibility.

    GetCloudInstanceSnapshotsSnapshotLocation

    Region string
    Region where the instance snapshots reside.
    Region string
    Region where the instance snapshots reside.
    region string
    Region where the instance snapshots reside.
    region String
    Region where the instance snapshots reside.
    region string
    Region where the instance snapshots reside.
    region str
    Region where the instance snapshots reside.
    region String
    Region where the instance snapshots 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.21.0
    published on Friday, Sep 25, 2026 by OVHcloud

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial