1. Packages
  2. Grafana Cloud
  3. API Docs
  4. getOncallSchedule
Grafana v0.16.3 published on Monday, Apr 7, 2025 by pulumiverse

grafana.getOncallSchedule

Explore with Pulumi AI

Grafana v0.16.3 published on Monday, Apr 7, 2025 by pulumiverse
Deprecated: grafana.index/getoncallschedule.getOncallSchedule has been deprecated in favor of grafana.oncall/getschedule.getSchedule

Example Usage

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

const schedule = grafana.onCall.getSchedule({
    name: "example_schedule",
});
Copy
import pulumi
import pulumi_grafana as grafana

schedule = grafana.onCall.get_schedule(name="example_schedule")
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumiverse/pulumi-grafana/sdk/go/grafana/oncall"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := oncall.GetSchedule(ctx, &oncall.GetScheduleArgs{
			Name: "example_schedule",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Grafana = Pulumi.Grafana;

return await Deployment.RunAsync(() => 
{
    var schedule = Grafana.OnCall.GetSchedule.Invoke(new()
    {
        Name = "example_schedule",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.grafana.onCall.OnCallFunctions;
import com.pulumi.grafana.onCall.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 schedule = OnCallFunctions.getSchedule(GetScheduleArgs.builder()
            .name("example_schedule")
            .build());

    }
}
Copy
variables:
  schedule:
    fn::invoke:
      function: grafana:onCall:getSchedule
      arguments:
        name: example_schedule
Copy

Using getOncallSchedule

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 getOncallSchedule(args: GetOncallScheduleArgs, opts?: InvokeOptions): Promise<GetOncallScheduleResult>
function getOncallScheduleOutput(args: GetOncallScheduleOutputArgs, opts?: InvokeOptions): Output<GetOncallScheduleResult>
Copy
def get_oncall_schedule(name: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetOncallScheduleResult
def get_oncall_schedule_output(name: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetOncallScheduleResult]
Copy
func LookupOncallSchedule(ctx *Context, args *LookupOncallScheduleArgs, opts ...InvokeOption) (*LookupOncallScheduleResult, error)
func LookupOncallScheduleOutput(ctx *Context, args *LookupOncallScheduleOutputArgs, opts ...InvokeOption) LookupOncallScheduleResultOutput
Copy

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

public static class GetOncallSchedule 
{
    public static Task<GetOncallScheduleResult> InvokeAsync(GetOncallScheduleArgs args, InvokeOptions? opts = null)
    public static Output<GetOncallScheduleResult> Invoke(GetOncallScheduleInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetOncallScheduleResult> getOncallSchedule(GetOncallScheduleArgs args, InvokeOptions options)
public static Output<GetOncallScheduleResult> getOncallSchedule(GetOncallScheduleArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: grafana:index/getOncallSchedule:getOncallSchedule
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Name This property is required. string
The schedule name.
Name This property is required. string
The schedule name.
name This property is required. String
The schedule name.
name This property is required. string
The schedule name.
name This property is required. str
The schedule name.
name This property is required. String
The schedule name.

getOncallSchedule Result

The following output properties are available:

Id string
The provider-assigned unique ID for this managed resource.
Name string
The schedule name.
Type string
The schedule type.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The schedule name.
Type string
The schedule type.
id String
The provider-assigned unique ID for this managed resource.
name String
The schedule name.
type String
The schedule type.
id string
The provider-assigned unique ID for this managed resource.
name string
The schedule name.
type string
The schedule type.
id str
The provider-assigned unique ID for this managed resource.
name str
The schedule name.
type str
The schedule type.
id String
The provider-assigned unique ID for this managed resource.
name String
The schedule name.
type String
The schedule type.

Package Details

Repository
grafana pulumiverse/pulumi-grafana
License
Apache-2.0
Notes
This Pulumi package is based on the grafana Terraform Provider.
Grafana v0.16.3 published on Monday, Apr 7, 2025 by pulumiverse