1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. ResourceScheduler
  5. getSchedule
Oracle Cloud Infrastructure v2.30.0 published on Monday, Apr 14, 2025 by Pulumi

oci.ResourceScheduler.getSchedule

Explore with Pulumi AI

Oracle Cloud Infrastructure v2.30.0 published on Monday, Apr 14, 2025 by Pulumi

This data source provides details about a specific Schedule resource in Oracle Cloud Infrastructure Resource Scheduler service.

This API gets information about a schedule.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testSchedule = oci.ResourceScheduler.getSchedule({
    scheduleId: testScheduleOciResourceSchedulerSchedule.id,
});
Copy
import pulumi
import pulumi_oci as oci

test_schedule = oci.ResourceScheduler.get_schedule(schedule_id=test_schedule_oci_resource_scheduler_schedule["id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/resourcescheduler"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := resourcescheduler.GetSchedule(ctx, &resourcescheduler.GetScheduleArgs{
			ScheduleId: testScheduleOciResourceSchedulerSchedule.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;

return await Deployment.RunAsync(() => 
{
    var testSchedule = Oci.ResourceScheduler.GetSchedule.Invoke(new()
    {
        ScheduleId = testScheduleOciResourceSchedulerSchedule.Id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.ResourceScheduler.ResourceSchedulerFunctions;
import com.pulumi.oci.ResourceScheduler.inputs.GetScheduleArgs;
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 testSchedule = ResourceSchedulerFunctions.getSchedule(GetScheduleArgs.builder()
            .scheduleId(testScheduleOciResourceSchedulerSchedule.id())
            .build());

    }
}
Copy
variables:
  testSchedule:
    fn::invoke:
      function: oci:ResourceScheduler:getSchedule
      arguments:
        scheduleId: ${testScheduleOciResourceSchedulerSchedule.id}
Copy

Using getSchedule

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 getSchedule(args: GetScheduleArgs, opts?: InvokeOptions): Promise<GetScheduleResult>
function getScheduleOutput(args: GetScheduleOutputArgs, opts?: InvokeOptions): Output<GetScheduleResult>
Copy
def get_schedule(schedule_id: Optional[str] = None,
                 opts: Optional[InvokeOptions] = None) -> GetScheduleResult
def get_schedule_output(schedule_id: Optional[pulumi.Input[str]] = None,
                 opts: Optional[InvokeOptions] = None) -> Output[GetScheduleResult]
Copy
func GetSchedule(ctx *Context, args *GetScheduleArgs, opts ...InvokeOption) (*GetScheduleResult, error)
func GetScheduleOutput(ctx *Context, args *GetScheduleOutputArgs, opts ...InvokeOption) GetScheduleResultOutput
Copy

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

public static class GetSchedule 
{
    public static Task<GetScheduleResult> InvokeAsync(GetScheduleArgs args, InvokeOptions? opts = null)
    public static Output<GetScheduleResult> Invoke(GetScheduleInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetScheduleResult> getSchedule(GetScheduleArgs args, InvokeOptions options)
public static Output<GetScheduleResult> getSchedule(GetScheduleArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: oci:ResourceScheduler/getSchedule:getSchedule
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

ScheduleId This property is required. string
This is the OCID of the schedule.
ScheduleId This property is required. string
This is the OCID of the schedule.
scheduleId This property is required. String
This is the OCID of the schedule.
scheduleId This property is required. string
This is the OCID of the schedule.
schedule_id This property is required. str
This is the OCID of the schedule.
scheduleId This property is required. String
This is the OCID of the schedule.

getSchedule Result

The following output properties are available:

Action string
This is the action that will be executed by the schedule.
CompartmentId string
The OCID of the compartment in which the schedule is created
DefinedTags Dictionary<string, string>
These are defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
Description string
This is the description of the schedule.
DisplayName string
This is a user-friendly name for the schedule. It does not have to be unique, and it's changeable.
FreeformTags Dictionary<string, string>
These are 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
This is the resource OCID.
RecurrenceDetails string
This is the frequency of recurrence of a schedule. The frequency field can either conform to RFC-5545 formatting or UNIX cron formatting for recurrences, based on the value specified by the recurrenceType field.
RecurrenceType string
Type of recurrence of a schedule
ResourceFilters List<GetScheduleResourceFilter>
This is a list of resources filters. The schedule will be applied to resources matching all of them.
Resources List<GetScheduleResource>
This is the list of resources to which the scheduled operation is applied.
ScheduleId string
State string
This is the current state of a schedule.
SystemTags Dictionary<string, string>
These are system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
TimeCreated string
This is the date and time the schedule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
TimeEnds string
This is the date and time the schedule ends, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
TimeLastRun string
This is the date and time the schedule runs last time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
TimeNextRun string
This is the date and time the schedule run the next time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
TimeStarts string
This is the date and time the schedule starts, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
TimeUpdated string
This is the date and time the schedule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
Action string
This is the action that will be executed by the schedule.
CompartmentId string
The OCID of the compartment in which the schedule is created
DefinedTags map[string]string
These are defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
Description string
This is the description of the schedule.
DisplayName string
This is a user-friendly name for the schedule. It does not have to be unique, and it's changeable.
FreeformTags map[string]string
These are 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
This is the resource OCID.
RecurrenceDetails string
This is the frequency of recurrence of a schedule. The frequency field can either conform to RFC-5545 formatting or UNIX cron formatting for recurrences, based on the value specified by the recurrenceType field.
RecurrenceType string
Type of recurrence of a schedule
ResourceFilters []GetScheduleResourceFilter
This is a list of resources filters. The schedule will be applied to resources matching all of them.
Resources []GetScheduleResource
This is the list of resources to which the scheduled operation is applied.
ScheduleId string
State string
This is the current state of a schedule.
SystemTags map[string]string
These are system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
TimeCreated string
This is the date and time the schedule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
TimeEnds string
This is the date and time the schedule ends, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
TimeLastRun string
This is the date and time the schedule runs last time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
TimeNextRun string
This is the date and time the schedule run the next time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
TimeStarts string
This is the date and time the schedule starts, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
TimeUpdated string
This is the date and time the schedule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
action String
This is the action that will be executed by the schedule.
compartmentId String
The OCID of the compartment in which the schedule is created
definedTags Map<String,String>
These are defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
description String
This is the description of the schedule.
displayName String
This is a user-friendly name for the schedule. It does not have to be unique, and it's changeable.
freeformTags Map<String,String>
These are 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
This is the resource OCID.
recurrenceDetails String
This is the frequency of recurrence of a schedule. The frequency field can either conform to RFC-5545 formatting or UNIX cron formatting for recurrences, based on the value specified by the recurrenceType field.
recurrenceType String
Type of recurrence of a schedule
resourceFilters List<GetScheduleResourceFilter>
This is a list of resources filters. The schedule will be applied to resources matching all of them.
resources List<GetScheduleResource>
This is the list of resources to which the scheduled operation is applied.
scheduleId String
state String
This is the current state of a schedule.
systemTags Map<String,String>
These are system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
timeCreated String
This is the date and time the schedule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeEnds String
This is the date and time the schedule ends, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
timeLastRun String
This is the date and time the schedule runs last time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeNextRun String
This is the date and time the schedule run the next time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeStarts String
This is the date and time the schedule starts, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
timeUpdated String
This is the date and time the schedule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
action string
This is the action that will be executed by the schedule.
compartmentId string
The OCID of the compartment in which the schedule is created
definedTags {[key: string]: string}
These are defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
description string
This is the description of the schedule.
displayName string
This is a user-friendly name for the schedule. It does not have to be unique, and it's changeable.
freeformTags {[key: string]: string}
These are 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
This is the resource OCID.
recurrenceDetails string
This is the frequency of recurrence of a schedule. The frequency field can either conform to RFC-5545 formatting or UNIX cron formatting for recurrences, based on the value specified by the recurrenceType field.
recurrenceType string
Type of recurrence of a schedule
resourceFilters GetScheduleResourceFilter[]
This is a list of resources filters. The schedule will be applied to resources matching all of them.
resources GetScheduleResource[]
This is the list of resources to which the scheduled operation is applied.
scheduleId string
state string
This is the current state of a schedule.
systemTags {[key: string]: string}
These are system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
timeCreated string
This is the date and time the schedule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeEnds string
This is the date and time the schedule ends, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
timeLastRun string
This is the date and time the schedule runs last time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeNextRun string
This is the date and time the schedule run the next time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeStarts string
This is the date and time the schedule starts, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
timeUpdated string
This is the date and time the schedule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
action str
This is the action that will be executed by the schedule.
compartment_id str
The OCID of the compartment in which the schedule is created
defined_tags Mapping[str, str]
These are defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
description str
This is the description of the schedule.
display_name str
This is a user-friendly name for the schedule. It does not have to be unique, and it's changeable.
freeform_tags Mapping[str, str]
These are 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
This is the resource OCID.
recurrence_details str
This is the frequency of recurrence of a schedule. The frequency field can either conform to RFC-5545 formatting or UNIX cron formatting for recurrences, based on the value specified by the recurrenceType field.
recurrence_type str
Type of recurrence of a schedule
resource_filters Sequence[resourcescheduler.GetScheduleResourceFilter]
This is a list of resources filters. The schedule will be applied to resources matching all of them.
resources Sequence[resourcescheduler.GetScheduleResource]
This is the list of resources to which the scheduled operation is applied.
schedule_id str
state str
This is the current state of a schedule.
system_tags Mapping[str, str]
These are system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
time_created str
This is the date and time the schedule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
time_ends str
This is the date and time the schedule ends, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
time_last_run str
This is the date and time the schedule runs last time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
time_next_run str
This is the date and time the schedule run the next time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
time_starts str
This is the date and time the schedule starts, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
time_updated str
This is the date and time the schedule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
action String
This is the action that will be executed by the schedule.
compartmentId String
The OCID of the compartment in which the schedule is created
definedTags Map<String>
These are defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
description String
This is the description of the schedule.
displayName String
This is a user-friendly name for the schedule. It does not have to be unique, and it's changeable.
freeformTags Map<String>
These are 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
This is the resource OCID.
recurrenceDetails String
This is the frequency of recurrence of a schedule. The frequency field can either conform to RFC-5545 formatting or UNIX cron formatting for recurrences, based on the value specified by the recurrenceType field.
recurrenceType String
Type of recurrence of a schedule
resourceFilters List<Property Map>
This is a list of resources filters. The schedule will be applied to resources matching all of them.
resources List<Property Map>
This is the list of resources to which the scheduled operation is applied.
scheduleId String
state String
This is the current state of a schedule.
systemTags Map<String>
These are system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
timeCreated String
This is the date and time the schedule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeEnds String
This is the date and time the schedule ends, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
timeLastRun String
This is the date and time the schedule runs last time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeNextRun String
This is the date and time the schedule run the next time, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
timeStarts String
This is the date and time the schedule starts, in the format defined by RFC 3339 Example: 2016-08-25T21:10:29.600Z
timeUpdated String
This is the date and time the schedule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z

Supporting Types

GetScheduleResource

Id This property is required. string
This is the resource OCID.
Metadata This property is required. Dictionary<string, string>
This is additional information that helps to identity the resource for the schedule.
Id This property is required. string
This is the resource OCID.
Metadata This property is required. map[string]string
This is additional information that helps to identity the resource for the schedule.
id This property is required. String
This is the resource OCID.
metadata This property is required. Map<String,String>
This is additional information that helps to identity the resource for the schedule.
id This property is required. string
This is the resource OCID.
metadata This property is required. {[key: string]: string}
This is additional information that helps to identity the resource for the schedule.
id This property is required. str
This is the resource OCID.
metadata This property is required. Mapping[str, str]
This is additional information that helps to identity the resource for the schedule.
id This property is required. String
This is the resource OCID.
metadata This property is required. Map<String>
This is additional information that helps to identity the resource for the schedule.

GetScheduleResourceFilter

Attribute This property is required. string
This is the resource attribute on which the threshold is defined.
Condition This property is required. string
This is the condition for the filter in comparison to its creation time.
ShouldIncludeChildCompartments This property is required. bool
This sets whether to include child compartments.
Values This property is required. List<GetScheduleResourceFilterValue>
This is the value of the defined tag.
Attribute This property is required. string
This is the resource attribute on which the threshold is defined.
Condition This property is required. string
This is the condition for the filter in comparison to its creation time.
ShouldIncludeChildCompartments This property is required. bool
This sets whether to include child compartments.
Values This property is required. []GetScheduleResourceFilterValue
This is the value of the defined tag.
attribute This property is required. String
This is the resource attribute on which the threshold is defined.
condition This property is required. String
This is the condition for the filter in comparison to its creation time.
shouldIncludeChildCompartments This property is required. Boolean
This sets whether to include child compartments.
values This property is required. List<GetScheduleResourceFilterValue>
This is the value of the defined tag.
attribute This property is required. string
This is the resource attribute on which the threshold is defined.
condition This property is required. string
This is the condition for the filter in comparison to its creation time.
shouldIncludeChildCompartments This property is required. boolean
This sets whether to include child compartments.
values This property is required. GetScheduleResourceFilterValue[]
This is the value of the defined tag.
attribute This property is required. str
This is the resource attribute on which the threshold is defined.
condition This property is required. str
This is the condition for the filter in comparison to its creation time.
should_include_child_compartments This property is required. bool
This sets whether to include child compartments.
values This property is required. Sequence[resourcescheduler.GetScheduleResourceFilterValue]
This is the value of the defined tag.
attribute This property is required. String
This is the resource attribute on which the threshold is defined.
condition This property is required. String
This is the condition for the filter in comparison to its creation time.
shouldIncludeChildCompartments This property is required. Boolean
This sets whether to include child compartments.
values This property is required. List<Property Map>
This is the value of the defined tag.

GetScheduleResourceFilterValue

Namespace This property is required. string
This is the namespace of the defined tag.
TagKey This property is required. string
This is the key of the defined tag.
Value This property is required. string
This is the value of the defined tag.
Namespace This property is required. string
This is the namespace of the defined tag.
TagKey This property is required. string
This is the key of the defined tag.
Value This property is required. string
This is the value of the defined tag.
namespace This property is required. String
This is the namespace of the defined tag.
tagKey This property is required. String
This is the key of the defined tag.
value This property is required. String
This is the value of the defined tag.
namespace This property is required. string
This is the namespace of the defined tag.
tagKey This property is required. string
This is the key of the defined tag.
value This property is required. string
This is the value of the defined tag.
namespace This property is required. str
This is the namespace of the defined tag.
tag_key This property is required. str
This is the key of the defined tag.
value This property is required. str
This is the value of the defined tag.
namespace This property is required. String
This is the namespace of the defined tag.
tagKey This property is required. String
This is the key of the defined tag.
value This property is required. String
This is the value of the defined tag.

Package Details

Repository
oci pulumi/pulumi-oci
License
Apache-2.0
Notes
This Pulumi package is based on the oci Terraform Provider.
Oracle Cloud Infrastructure v2.30.0 published on Monday, Apr 14, 2025 by Pulumi