1. Registry
  2. Packages
  3. Incident Provider
  4. API Docs
  5. getScheduleSyncRule
Viewing docs for incident 7.0.0
published on Friday, Sep 11, 2026 by incident-io
Viewing docs for incident 7.0.0
published on Friday, Sep 11, 2026 by incident-io

    Look up an existing schedule sync rule by schedule ID and rule ID.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as incident from "@pulumi/incident";
    
    // Look up a schedule sync rule by schedule ID and rule ID.
    const platformOncall = incident.getScheduleSyncRule({
        scheduleId: platform.id,
        id: "01MNO456PQR789STU012VWX",
    });
    
    import pulumi
    import pulumi_incident as incident
    
    # Look up a schedule sync rule by schedule ID and rule ID.
    platform_oncall = incident.get_schedule_sync_rule(schedule_id=platform["id"],
        id="01MNO456PQR789STU012VWX")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/incident/v7/incident"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Look up a schedule sync rule by schedule ID and rule ID.
    		_, err := incident.LookupScheduleSyncRule(ctx, &incident.LookupScheduleSyncRuleArgs{
    			ScheduleId: platform.Id,
    			Id:         "01MNO456PQR789STU012VWX",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Incident = Pulumi.Incident;
    
    return await Deployment.RunAsync(() => 
    {
        // Look up a schedule sync rule by schedule ID and rule ID.
        var platformOncall = Incident.GetScheduleSyncRule.Invoke(new()
        {
            ScheduleId = platform.Id,
            Id = "01MNO456PQR789STU012VWX",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.incident.IncidentFunctions;
    import com.pulumi.incident.inputs.GetScheduleSyncRuleArgs;
    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) {
            // Look up a schedule sync rule by schedule ID and rule ID.
            final var platformOncall = IncidentFunctions.getScheduleSyncRule(GetScheduleSyncRuleArgs.builder()
                .scheduleId(platform.id())
                .id("01MNO456PQR789STU012VWX")
                .build());
    
        }
    }
    
    variables:
      # Look up a schedule sync rule by schedule ID and rule ID.
      platformOncall:
        fn::invoke:
          function: incident:getScheduleSyncRule
          arguments:
            scheduleId: ${platform.id}
            id: 01MNO456PQR789STU012VWX
    
    Example coming soon!
    

    Using getScheduleSyncRule

    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 getScheduleSyncRule(args: GetScheduleSyncRuleArgs, opts?: InvokeOptions): Promise<GetScheduleSyncRuleResult>
    function getScheduleSyncRuleOutput(args: GetScheduleSyncRuleOutputArgs, opts?: InvokeOutputOptions): Output<GetScheduleSyncRuleResult>
    def get_schedule_sync_rule(id: Optional[str] = None,
                               schedule_id: Optional[str] = None,
                               opts: Optional[InvokeOptions] = None) -> GetScheduleSyncRuleResult
    def get_schedule_sync_rule_output(id: pulumi.Input[Optional[str]] = None,
                               schedule_id: pulumi.Input[Optional[str]] = None,
                               opts: Optional[InvokeOutputOptions] = None) -> Output[GetScheduleSyncRuleResult]
    func LookupScheduleSyncRule(ctx *Context, args *LookupScheduleSyncRuleArgs, opts ...InvokeOption) (*LookupScheduleSyncRuleResult, error)
    func LookupScheduleSyncRuleOutput(ctx *Context, args *LookupScheduleSyncRuleOutputArgs, opts ...InvokeOption) LookupScheduleSyncRuleResultOutput

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

    public static class GetScheduleSyncRule 
    {
        public static Task<GetScheduleSyncRuleResult> InvokeAsync(GetScheduleSyncRuleArgs args, InvokeOptions? opts = null)
        public static Output<GetScheduleSyncRuleResult> Invoke(GetScheduleSyncRuleInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetScheduleSyncRuleResult> Invoke(GetScheduleSyncRuleInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetScheduleSyncRuleResult> getScheduleSyncRule(GetScheduleSyncRuleArgs args, InvokeOptions options)
    public static Output<GetScheduleSyncRuleResult> getScheduleSyncRule(GetScheduleSyncRuleArgs args, InvokeOptions options)
    public static Output<GetScheduleSyncRuleResult> getScheduleSyncRule(GetScheduleSyncRuleArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: incident:index/getScheduleSyncRule:getScheduleSyncRule
      arguments:
        # arguments dictionary
    data "incident_get_schedule_sync_rule" "name" {
        # arguments
    }

    The following arguments are supported:

    Id string
    Unique identifier of the sync rule
    ScheduleId string
    The schedule this rule belongs to
    Id string
    Unique identifier of the sync rule
    ScheduleId string
    The schedule this rule belongs to
    id string
    Unique identifier of the sync rule
    schedule_id string
    The schedule this rule belongs to
    id String
    Unique identifier of the sync rule
    scheduleId String
    The schedule this rule belongs to
    id string
    Unique identifier of the sync rule
    scheduleId string
    The schedule this rule belongs to
    id str
    Unique identifier of the sync rule
    schedule_id str
    The schedule this rule belongs to
    id String
    Unique identifier of the sync rule
    scheduleId String
    The schedule this rule belongs to

    getScheduleSyncRule Result

    The following output properties are available:

    Id string
    Unique identifier of the sync rule
    PermanentMemberUserIds List<string>
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    RotationId string
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    ScheduleId string
    The schedule this rule belongs to
    ScheduleSyncTargetId string
    The sync target ID this rule links to
    SyncType string
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.
    Id string
    Unique identifier of the sync rule
    PermanentMemberUserIds []string
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    RotationId string
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    ScheduleId string
    The schedule this rule belongs to
    ScheduleSyncTargetId string
    The sync target ID this rule links to
    SyncType string
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.
    id string
    Unique identifier of the sync rule
    permanent_member_user_ids list(string)
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    rotation_id string
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    schedule_id string
    The schedule this rule belongs to
    schedule_sync_target_id string
    The sync target ID this rule links to
    sync_type string
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.
    id String
    Unique identifier of the sync rule
    permanentMemberUserIds List<String>
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    rotationId String
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    scheduleId String
    The schedule this rule belongs to
    scheduleSyncTargetId String
    The sync target ID this rule links to
    syncType String
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.
    id string
    Unique identifier of the sync rule
    permanentMemberUserIds string[]
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    rotationId string
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    scheduleId string
    The schedule this rule belongs to
    scheduleSyncTargetId string
    The sync target ID this rule links to
    syncType string
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.
    id str
    Unique identifier of the sync rule
    permanent_member_user_ids Sequence[str]
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    rotation_id str
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    schedule_id str
    The schedule this rule belongs to
    schedule_sync_target_id str
    The sync target ID this rule links to
    sync_type str
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.
    id String
    Unique identifier of the sync rule
    permanentMemberUserIds List<String>
    IDs of users always kept in the Slack user group, regardless of who is on call. Useful for keeping e.g. a manager in the group so they see mentions without being paged. Scoped to this rule: when several rules feed the same group, we sync the union of their permanent members.
    rotationId String
    If set, only members of this rotation sync to the user group. When unset, all rotations on the schedule are synced.
    scheduleId String
    The schedule this rule belongs to
    scheduleSyncTargetId String
    The sync target ID this rule links to
    syncType String
    Which schedule members sync to the user group. Possible values are: on_call, all_users, next_on_call.

    Package Details

    Repository
    incident incident-io/terraform-provider-incident
    License
    Notes
    This Pulumi package is based on the incident Terraform Provider.
    Viewing docs for incident 7.0.0
    published on Friday, Sep 11, 2026 by incident-io

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial