Oracle Cloud Infrastructure v3.9.0 published on Wednesday, Sep 24, 2025 by Pulumi
oci.Core.getVolumeBackupPolicies
This data source provides the list of Volume Backup Policies in Oracle Cloud Infrastructure Core service.
Lists all the volume backup policies available in the specified compartment.
For more information about Oracle defined backup policies and user defined backup policies, see Policy-Based Backups.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testVolumeBackupPolicies = oci.Core.getVolumeBackupPolicies({
    compartmentId: compartmentId,
});
import pulumi
import pulumi_oci as oci
test_volume_backup_policies = oci.Core.get_volume_backup_policies(compartment_id=compartment_id)
package main
import (
	"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/core"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := core.GetVolumeBackupPolicies(ctx, &core.GetVolumeBackupPoliciesArgs{
			CompartmentId: pulumi.StringRef(compartmentId),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() => 
{
    var testVolumeBackupPolicies = Oci.Core.GetVolumeBackupPolicies.Invoke(new()
    {
        CompartmentId = compartmentId,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Core.CoreFunctions;
import com.pulumi.oci.Core.inputs.GetVolumeBackupPoliciesArgs;
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 testVolumeBackupPolicies = CoreFunctions.getVolumeBackupPolicies(GetVolumeBackupPoliciesArgs.builder()
            .compartmentId(compartmentId)
            .build());
    }
}
variables:
  testVolumeBackupPolicies:
    fn::invoke:
      function: oci:Core:getVolumeBackupPolicies
      arguments:
        compartmentId: ${compartmentId}
Using getVolumeBackupPolicies
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 getVolumeBackupPolicies(args: GetVolumeBackupPoliciesArgs, opts?: InvokeOptions): Promise<GetVolumeBackupPoliciesResult>
function getVolumeBackupPoliciesOutput(args: GetVolumeBackupPoliciesOutputArgs, opts?: InvokeOptions): Output<GetVolumeBackupPoliciesResult>def get_volume_backup_policies(compartment_id: Optional[str] = None,
                               filters: Optional[Sequence[GetVolumeBackupPoliciesFilter]] = None,
                               opts: Optional[InvokeOptions] = None) -> GetVolumeBackupPoliciesResult
def get_volume_backup_policies_output(compartment_id: Optional[pulumi.Input[str]] = None,
                               filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetVolumeBackupPoliciesFilterArgs]]]] = None,
                               opts: Optional[InvokeOptions] = None) -> Output[GetVolumeBackupPoliciesResult]func GetVolumeBackupPolicies(ctx *Context, args *GetVolumeBackupPoliciesArgs, opts ...InvokeOption) (*GetVolumeBackupPoliciesResult, error)
func GetVolumeBackupPoliciesOutput(ctx *Context, args *GetVolumeBackupPoliciesOutputArgs, opts ...InvokeOption) GetVolumeBackupPoliciesResultOutput> Note: This function is named GetVolumeBackupPolicies in the Go SDK.
public static class GetVolumeBackupPolicies 
{
    public static Task<GetVolumeBackupPoliciesResult> InvokeAsync(GetVolumeBackupPoliciesArgs args, InvokeOptions? opts = null)
    public static Output<GetVolumeBackupPoliciesResult> Invoke(GetVolumeBackupPoliciesInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetVolumeBackupPoliciesResult> getVolumeBackupPolicies(GetVolumeBackupPoliciesArgs args, InvokeOptions options)
public static Output<GetVolumeBackupPoliciesResult> getVolumeBackupPolicies(GetVolumeBackupPoliciesArgs args, InvokeOptions options)
fn::invoke:
  function: oci:Core/getVolumeBackupPolicies:getVolumeBackupPolicies
  arguments:
    # arguments dictionaryThe following arguments are supported:
- CompartmentId string
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- Filters
List<GetVolume Backup Policies Filter> 
- CompartmentId string
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- Filters
[]GetVolume Backup Policies Filter 
- compartmentId String
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- filters
List<GetVolume Backup Policies Filter> 
- compartmentId string
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- filters
GetVolume Backup Policies Filter[] 
- compartment_id str
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- filters
Sequence[GetVolume Backup Policies Filter] 
- compartmentId String
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- filters List<Property Map>
getVolumeBackupPolicies Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- VolumeBackup List<GetPolicies Volume Backup Policies Volume Backup Policy> 
- The list of volume_backup_policies.
- CompartmentId string
- The OCID of the compartment that contains the volume backup.
- Filters
List<GetVolume Backup Policies Filter> 
- Id string
- The provider-assigned unique ID for this managed resource.
- VolumeBackup []GetPolicies Volume Backup Policies Volume Backup Policy 
- The list of volume_backup_policies.
- CompartmentId string
- The OCID of the compartment that contains the volume backup.
- Filters
[]GetVolume Backup Policies Filter 
- id String
- The provider-assigned unique ID for this managed resource.
- volumeBackup List<GetPolicies Volume Backup Policies Volume Backup Policy> 
- The list of volume_backup_policies.
- compartmentId String
- The OCID of the compartment that contains the volume backup.
- filters
List<GetVolume Backup Policies Filter> 
- id string
- The provider-assigned unique ID for this managed resource.
- volumeBackup GetPolicies Volume Backup Policies Volume Backup Policy[] 
- The list of volume_backup_policies.
- compartmentId string
- The OCID of the compartment that contains the volume backup.
- filters
GetVolume Backup Policies Filter[] 
- id str
- The provider-assigned unique ID for this managed resource.
- volume_backup_ Sequence[Getpolicies Volume Backup Policies Volume Backup Policy] 
- The list of volume_backup_policies.
- compartment_id str
- The OCID of the compartment that contains the volume backup.
- filters
Sequence[GetVolume Backup Policies Filter] 
- id String
- The provider-assigned unique ID for this managed resource.
- volumeBackup List<Property Map>Policies 
- The list of volume_backup_policies.
- compartmentId String
- The OCID of the compartment that contains the volume backup.
- filters List<Property Map>
Supporting Types
GetVolumeBackupPoliciesFilter    
GetVolumeBackupPoliciesVolumeBackupPolicy      
- CompartmentId string
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- Dictionary<string, string>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- DestinationRegion string
- The paired destination region for copying scheduled backups to. Example us-ashburn-1. See Region Pairs for details about paired regions.
- DisplayName string
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Dictionary<string, string>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- Id string
- The OCID of the volume backup policy.
- Schedules
List<GetVolume Backup Policies Volume Backup Policy Schedule> 
- The collection of schedules that this policy will apply.
- TimeCreated string
- The date and time the volume backup policy was created. Format defined by RFC3339.
- CompartmentId string
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- map[string]string
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- DestinationRegion string
- The paired destination region for copying scheduled backups to. Example us-ashburn-1. See Region Pairs for details about paired regions.
- DisplayName string
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- map[string]string
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- Id string
- The OCID of the volume backup policy.
- Schedules
[]GetVolume Backup Policies Volume Backup Policy Schedule 
- The collection of schedules that this policy will apply.
- TimeCreated string
- The date and time the volume backup policy was created. Format defined by RFC3339.
- compartmentId String
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- Map<String,String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- destinationRegion String
- The paired destination region for copying scheduled backups to. Example us-ashburn-1. See Region Pairs for details about paired regions.
- displayName String
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Map<String,String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id String
- The OCID of the volume backup policy.
- schedules
List<GetVolume Backup Policies Volume Backup Policy Schedule> 
- The collection of schedules that this policy will apply.
- timeCreated String
- The date and time the volume backup policy was created. Format defined by RFC3339.
- compartmentId string
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- {[key: string]: string}
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- destinationRegion string
- The paired destination region for copying scheduled backups to. Example us-ashburn-1. See Region Pairs for details about paired regions.
- displayName string
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- {[key: string]: string}
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id string
- The OCID of the volume backup policy.
- schedules
GetVolume Backup Policies Volume Backup Policy Schedule[] 
- The collection of schedules that this policy will apply.
- timeCreated string
- The date and time the volume backup policy was created. Format defined by RFC3339.
- compartment_id str
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- Mapping[str, str]
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- destination_region str
- The paired destination region for copying scheduled backups to. Example us-ashburn-1. See Region Pairs for details about paired regions.
- display_name str
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Mapping[str, str]
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id str
- The OCID of the volume backup policy.
- schedules
Sequence[GetVolume Backup Policies Volume Backup Policy Schedule] 
- The collection of schedules that this policy will apply.
- time_created str
- The date and time the volume backup policy was created. Format defined by RFC3339.
- compartmentId String
- The OCID of the compartment. If no compartment is specified, the Oracle defined backup policies are listed.
- Map<String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- destinationRegion String
- The paired destination region for copying scheduled backups to. Example us-ashburn-1. See Region Pairs for details about paired regions.
- displayName String
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Map<String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id String
- The OCID of the volume backup policy.
- schedules List<Property Map>
- The collection of schedules that this policy will apply.
- timeCreated String
- The date and time the volume backup policy was created. Format defined by RFC3339.
GetVolumeBackupPoliciesVolumeBackupPolicySchedule       
- BackupType string
- The type of volume backup to create.
- DayOf intMonth 
- The day of the month to schedule the volume backup.
- DayOf stringWeek 
- The day of the week to schedule the volume backup.
- HourOf intDay 
- The hour of the day to schedule the volume backup.
- Month string
- The month of the year to schedule the volume backup.
- OffsetSeconds int
- The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
- OffsetType string
- Indicates how the offset is defined. If value is STRUCTURED, thenhourOfDay,dayOfWeek,dayOfMonth, andmonthfields are used andoffsetSecondswill be ignored in requests and users should ignore its value from the responses.
- Period string
- The volume backup frequency.
- RetentionSeconds int
- How long, in seconds, to keep the volume backups created by this schedule.
- TimeZone string
- Specifies what time zone is the schedule in
- BackupType string
- The type of volume backup to create.
- DayOf intMonth 
- The day of the month to schedule the volume backup.
- DayOf stringWeek 
- The day of the week to schedule the volume backup.
- HourOf intDay 
- The hour of the day to schedule the volume backup.
- Month string
- The month of the year to schedule the volume backup.
- OffsetSeconds int
- The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
- OffsetType string
- Indicates how the offset is defined. If value is STRUCTURED, thenhourOfDay,dayOfWeek,dayOfMonth, andmonthfields are used andoffsetSecondswill be ignored in requests and users should ignore its value from the responses.
- Period string
- The volume backup frequency.
- RetentionSeconds int
- How long, in seconds, to keep the volume backups created by this schedule.
- TimeZone string
- Specifies what time zone is the schedule in
- backupType String
- The type of volume backup to create.
- dayOf IntegerMonth 
- The day of the month to schedule the volume backup.
- dayOf StringWeek 
- The day of the week to schedule the volume backup.
- hourOf IntegerDay 
- The hour of the day to schedule the volume backup.
- month String
- The month of the year to schedule the volume backup.
- offsetSeconds Integer
- The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
- offsetType String
- Indicates how the offset is defined. If value is STRUCTURED, thenhourOfDay,dayOfWeek,dayOfMonth, andmonthfields are used andoffsetSecondswill be ignored in requests and users should ignore its value from the responses.
- period String
- The volume backup frequency.
- retentionSeconds Integer
- How long, in seconds, to keep the volume backups created by this schedule.
- timeZone String
- Specifies what time zone is the schedule in
- backupType string
- The type of volume backup to create.
- dayOf numberMonth 
- The day of the month to schedule the volume backup.
- dayOf stringWeek 
- The day of the week to schedule the volume backup.
- hourOf numberDay 
- The hour of the day to schedule the volume backup.
- month string
- The month of the year to schedule the volume backup.
- offsetSeconds number
- The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
- offsetType string
- Indicates how the offset is defined. If value is STRUCTURED, thenhourOfDay,dayOfWeek,dayOfMonth, andmonthfields are used andoffsetSecondswill be ignored in requests and users should ignore its value from the responses.
- period string
- The volume backup frequency.
- retentionSeconds number
- How long, in seconds, to keep the volume backups created by this schedule.
- timeZone string
- Specifies what time zone is the schedule in
- backup_type str
- The type of volume backup to create.
- day_of_ intmonth 
- The day of the month to schedule the volume backup.
- day_of_ strweek 
- The day of the week to schedule the volume backup.
- hour_of_ intday 
- The hour of the day to schedule the volume backup.
- month str
- The month of the year to schedule the volume backup.
- offset_seconds int
- The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
- offset_type str
- Indicates how the offset is defined. If value is STRUCTURED, thenhourOfDay,dayOfWeek,dayOfMonth, andmonthfields are used andoffsetSecondswill be ignored in requests and users should ignore its value from the responses.
- period str
- The volume backup frequency.
- retention_seconds int
- How long, in seconds, to keep the volume backups created by this schedule.
- time_zone str
- Specifies what time zone is the schedule in
- backupType String
- The type of volume backup to create.
- dayOf NumberMonth 
- The day of the month to schedule the volume backup.
- dayOf StringWeek 
- The day of the week to schedule the volume backup.
- hourOf NumberDay 
- The hour of the day to schedule the volume backup.
- month String
- The month of the year to schedule the volume backup.
- offsetSeconds Number
- The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
- offsetType String
- Indicates how the offset is defined. If value is STRUCTURED, thenhourOfDay,dayOfWeek,dayOfMonth, andmonthfields are used andoffsetSecondswill be ignored in requests and users should ignore its value from the responses.
- period String
- The volume backup frequency.
- retentionSeconds Number
- How long, in seconds, to keep the volume backups created by this schedule.
- timeZone String
- Specifies what time zone is the schedule in
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.
