1. Registry
  2. Packages
  3. Datadog Provider
  4. API Docs
  5. getFleetSchedules
Viewing docs for Datadog v5.12.0
published on Friday, Sep 25, 2026 by Pulumi
datadog logo
Viewing docs for Datadog v5.12.0
published on Friday, Sep 25, 2026 by Pulumi

    Lists Fleet Automation Agent upgrade schedules in ID order. An empty result is successful. Reading schedules requires an application key with the hostsRead permission.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as datadog from "@pulumi/datadog";
    
    // Returns an empty list when the organization has no Fleet Automation schedules.
    const all = datadog.getFleetSchedules({});
    
    import pulumi
    import pulumi_datadog as datadog
    
    # Returns an empty list when the organization has no Fleet Automation schedules.
    all = datadog.get_fleet_schedules()
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-datadog/sdk/v5/go/datadog"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Returns an empty list when the organization has no Fleet Automation schedules.
    		_, err := datadog.GetFleetSchedules(ctx, map[string]interface{}{}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Datadog = Pulumi.Datadog;
    
    return await Deployment.RunAsync(() => 
    {
        // Returns an empty list when the organization has no Fleet Automation schedules.
        var all = Datadog.GetFleetSchedules.Invoke();
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.datadog.DatadogFunctions;
    import java.util.ArrayList;
    import java.util.Arrays;
    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) {
            // Returns an empty list when the organization has no Fleet Automation schedules.
            final var all = DatadogFunctions.getFleetSchedules(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference);
    
        }
    }
    
    variables:
      # Returns an empty list when the organization has no Fleet Automation schedules.
      all:
        fn::invoke:
          function: datadog:getFleetSchedules
          arguments: {}
    
    pulumi {
      required_providers {
        datadog = {
          source = "pulumi/datadog"
        }
      }
    }
    
    data "datadog_getfleetschedules" "all" {
    }
    
    # Returns an empty list when the organization has no Fleet Automation schedules.
    

    Using getFleetSchedules

    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 getFleetSchedules(opts?: InvokeOptions): Promise<GetFleetSchedulesResult>
    function getFleetSchedulesOutput(opts?: InvokeOutputOptions): Output<GetFleetSchedulesResult>
    def get_fleet_schedules(opts: Optional[InvokeOptions] = None) -> GetFleetSchedulesResult
    def get_fleet_schedules_output(opts: Optional[InvokeOutputOptions] = None) -> Output[GetFleetSchedulesResult]
    func GetFleetSchedules(ctx *Context, opts ...InvokeOption) (*GetFleetSchedulesResult, error)
    func GetFleetSchedulesOutput(ctx *Context, opts ...InvokeOption) GetFleetSchedulesResultOutput

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

    public static class GetFleetSchedules 
    {
        public static Task<GetFleetSchedulesResult> InvokeAsync(InvokeOptions? opts = null)
        public static Output<GetFleetSchedulesResult> Invoke(InvokeOptions? opts = null)
        public static Output<GetFleetSchedulesResult> Invoke(InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetFleetSchedulesResult> getFleetSchedules(InvokeOptions options)
    public static Output<GetFleetSchedulesResult> getFleetSchedules(InvokeOptions options)
    public static Output<GetFleetSchedulesResult> getFleetSchedules(InvokeOutputOptions options)
    
    fn::invoke:
      function: datadog:index/getFleetSchedules:getFleetSchedules
      arguments:
        # arguments dictionary
    data "datadog_get_fleet_schedules" "name" {
        # arguments
    }

    getFleetSchedules Result

    The following output properties are available:

    Schedules List<GetFleetSchedulesSchedule>
    Fleet Automation schedules, sorted by ID.
    TotalCount int
    Total number of schedules returned by the API.
    Schedules []GetFleetSchedulesSchedule
    Fleet Automation schedules, sorted by ID.
    TotalCount int
    Total number of schedules returned by the API.
    schedules list(object)
    Fleet Automation schedules, sorted by ID.
    total_count number
    Total number of schedules returned by the API.
    schedules List<GetFleetSchedulesSchedule>
    Fleet Automation schedules, sorted by ID.
    totalCount Integer
    Total number of schedules returned by the API.
    schedules GetFleetSchedulesSchedule[]
    Fleet Automation schedules, sorted by ID.
    totalCount number
    Total number of schedules returned by the API.
    schedules Sequence[GetFleetSchedulesSchedule]
    Fleet Automation schedules, sorted by ID.
    total_count int
    Total number of schedules returned by the API.
    schedules List<Property Map>
    Fleet Automation schedules, sorted by ID.
    totalCount Number
    Total number of schedules returned by the API.

    Supporting Types

    GetFleetSchedulesSchedule

    CreatedAt string
    RFC 3339 timestamp when the schedule was created.
    CreatedBy string
    User handle of the person who created the schedule.
    Id string
    Unique identifier of the Fleet Automation schedule.
    IsDefault bool
    Whether this is the organization's default schedule.
    Name string
    Human-readable name of the schedule.
    NextRun string
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    NotificationRule GetFleetSchedulesScheduleNotificationRule
    Notification configuration attached to the schedule, when available.
    Query string
    Datadog host query used to select the Agent upgrade targets.
    Rule GetFleetSchedulesScheduleRule
    Recurrence and maintenance-window configuration for the schedule.
    Status string
    Whether the schedule is active or inactive.
    UpdatedAt string
    RFC 3339 timestamp when the schedule was last updated.
    UpdatedBy string
    User handle of the person who last updated the schedule.
    VersionToLatest int
    Number of major Agent versions behind the latest version targeted by the schedule.
    CreatedAt string
    RFC 3339 timestamp when the schedule was created.
    CreatedBy string
    User handle of the person who created the schedule.
    Id string
    Unique identifier of the Fleet Automation schedule.
    IsDefault bool
    Whether this is the organization's default schedule.
    Name string
    Human-readable name of the schedule.
    NextRun string
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    NotificationRule GetFleetSchedulesScheduleNotificationRule
    Notification configuration attached to the schedule, when available.
    Query string
    Datadog host query used to select the Agent upgrade targets.
    Rule GetFleetSchedulesScheduleRule
    Recurrence and maintenance-window configuration for the schedule.
    Status string
    Whether the schedule is active or inactive.
    UpdatedAt string
    RFC 3339 timestamp when the schedule was last updated.
    UpdatedBy string
    User handle of the person who last updated the schedule.
    VersionToLatest int
    Number of major Agent versions behind the latest version targeted by the schedule.
    created_at string
    RFC 3339 timestamp when the schedule was created.
    created_by string
    User handle of the person who created the schedule.
    id string
    Unique identifier of the Fleet Automation schedule.
    is_default bool
    Whether this is the organization's default schedule.
    name string
    Human-readable name of the schedule.
    next_run string
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    notification_rule object
    Notification configuration attached to the schedule, when available.
    query string
    Datadog host query used to select the Agent upgrade targets.
    rule object
    Recurrence and maintenance-window configuration for the schedule.
    status string
    Whether the schedule is active or inactive.
    updated_at string
    RFC 3339 timestamp when the schedule was last updated.
    updated_by string
    User handle of the person who last updated the schedule.
    version_to_latest number
    Number of major Agent versions behind the latest version targeted by the schedule.
    createdAt String
    RFC 3339 timestamp when the schedule was created.
    createdBy String
    User handle of the person who created the schedule.
    id String
    Unique identifier of the Fleet Automation schedule.
    isDefault Boolean
    Whether this is the organization's default schedule.
    name String
    Human-readable name of the schedule.
    nextRun String
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    notificationRule GetFleetSchedulesScheduleNotificationRule
    Notification configuration attached to the schedule, when available.
    query String
    Datadog host query used to select the Agent upgrade targets.
    rule GetFleetSchedulesScheduleRule
    Recurrence and maintenance-window configuration for the schedule.
    status String
    Whether the schedule is active or inactive.
    updatedAt String
    RFC 3339 timestamp when the schedule was last updated.
    updatedBy String
    User handle of the person who last updated the schedule.
    versionToLatest Integer
    Number of major Agent versions behind the latest version targeted by the schedule.
    createdAt string
    RFC 3339 timestamp when the schedule was created.
    createdBy string
    User handle of the person who created the schedule.
    id string
    Unique identifier of the Fleet Automation schedule.
    isDefault boolean
    Whether this is the organization's default schedule.
    name string
    Human-readable name of the schedule.
    nextRun string
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    notificationRule GetFleetSchedulesScheduleNotificationRule
    Notification configuration attached to the schedule, when available.
    query string
    Datadog host query used to select the Agent upgrade targets.
    rule GetFleetSchedulesScheduleRule
    Recurrence and maintenance-window configuration for the schedule.
    status string
    Whether the schedule is active or inactive.
    updatedAt string
    RFC 3339 timestamp when the schedule was last updated.
    updatedBy string
    User handle of the person who last updated the schedule.
    versionToLatest number
    Number of major Agent versions behind the latest version targeted by the schedule.
    created_at str
    RFC 3339 timestamp when the schedule was created.
    created_by str
    User handle of the person who created the schedule.
    id str
    Unique identifier of the Fleet Automation schedule.
    is_default bool
    Whether this is the organization's default schedule.
    name str
    Human-readable name of the schedule.
    next_run str
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    notification_rule GetFleetSchedulesScheduleNotificationRule
    Notification configuration attached to the schedule, when available.
    query str
    Datadog host query used to select the Agent upgrade targets.
    rule GetFleetSchedulesScheduleRule
    Recurrence and maintenance-window configuration for the schedule.
    status str
    Whether the schedule is active or inactive.
    updated_at str
    RFC 3339 timestamp when the schedule was last updated.
    updated_by str
    User handle of the person who last updated the schedule.
    version_to_latest int
    Number of major Agent versions behind the latest version targeted by the schedule.
    createdAt String
    RFC 3339 timestamp when the schedule was created.
    createdBy String
    User handle of the person who created the schedule.
    id String
    Unique identifier of the Fleet Automation schedule.
    isDefault Boolean
    Whether this is the organization's default schedule.
    name String
    Human-readable name of the schedule.
    nextRun String
    RFC 3339 timestamp of the next maintenance window, or null when no next run can be computed.
    notificationRule Property Map
    Notification configuration attached to the schedule, when available.
    query String
    Datadog host query used to select the Agent upgrade targets.
    rule Property Map
    Recurrence and maintenance-window configuration for the schedule.
    status String
    Whether the schedule is active or inactive.
    updatedAt String
    RFC 3339 timestamp when the schedule was last updated.
    updatedBy String
    User handle of the person who last updated the schedule.
    versionToLatest Number
    Number of major Agent versions behind the latest version targeted by the schedule.

    GetFleetSchedulesScheduleNotificationRule

    Handles List<string>
    Notification handles, such as Slack channels or PagerDuty integrations.
    Tags List<string>
    Tags associated with the notification rule.
    Handles []string
    Notification handles, such as Slack channels or PagerDuty integrations.
    Tags []string
    Tags associated with the notification rule.
    handles list(string)
    Notification handles, such as Slack channels or PagerDuty integrations.
    tags list(string)
    Tags associated with the notification rule.
    handles List<String>
    Notification handles, such as Slack channels or PagerDuty integrations.
    tags List<String>
    Tags associated with the notification rule.
    handles string[]
    Notification handles, such as Slack channels or PagerDuty integrations.
    tags string[]
    Tags associated with the notification rule.
    handles Sequence[str]
    Notification handles, such as Slack channels or PagerDuty integrations.
    tags Sequence[str]
    Tags associated with the notification rule.
    handles List<String>
    Notification handles, such as Slack channels or PagerDuty integrations.
    tags List<String>
    Tags associated with the notification rule.

    GetFleetSchedulesScheduleRule

    DaysOfWeeks List<string>
    Days when the schedule may run.
    Interval int
    Interval between schedule runs in weeks.
    MaintenanceWindowDuration int
    Duration of the maintenance window in minutes.
    StartMaintenanceWindow string
    Start of the maintenance window in canonical 24-hour HH:MM format.
    Timezone string
    IANA time zone used to interpret the maintenance window.
    DaysOfWeeks []string
    Days when the schedule may run.
    Interval int
    Interval between schedule runs in weeks.
    MaintenanceWindowDuration int
    Duration of the maintenance window in minutes.
    StartMaintenanceWindow string
    Start of the maintenance window in canonical 24-hour HH:MM format.
    Timezone string
    IANA time zone used to interpret the maintenance window.
    days_of_weeks list(string)
    Days when the schedule may run.
    interval number
    Interval between schedule runs in weeks.
    maintenance_window_duration number
    Duration of the maintenance window in minutes.
    start_maintenance_window string
    Start of the maintenance window in canonical 24-hour HH:MM format.
    timezone string
    IANA time zone used to interpret the maintenance window.
    daysOfWeeks List<String>
    Days when the schedule may run.
    interval Integer
    Interval between schedule runs in weeks.
    maintenanceWindowDuration Integer
    Duration of the maintenance window in minutes.
    startMaintenanceWindow String
    Start of the maintenance window in canonical 24-hour HH:MM format.
    timezone String
    IANA time zone used to interpret the maintenance window.
    daysOfWeeks string[]
    Days when the schedule may run.
    interval number
    Interval between schedule runs in weeks.
    maintenanceWindowDuration number
    Duration of the maintenance window in minutes.
    startMaintenanceWindow string
    Start of the maintenance window in canonical 24-hour HH:MM format.
    timezone string
    IANA time zone used to interpret the maintenance window.
    days_of_weeks Sequence[str]
    Days when the schedule may run.
    interval int
    Interval between schedule runs in weeks.
    maintenance_window_duration int
    Duration of the maintenance window in minutes.
    start_maintenance_window str
    Start of the maintenance window in canonical 24-hour HH:MM format.
    timezone str
    IANA time zone used to interpret the maintenance window.
    daysOfWeeks List<String>
    Days when the schedule may run.
    interval Number
    Interval between schedule runs in weeks.
    maintenanceWindowDuration Number
    Duration of the maintenance window in minutes.
    startMaintenanceWindow String
    Start of the maintenance window in canonical 24-hour HH:MM format.
    timezone String
    IANA time zone used to interpret the maintenance window.

    Package Details

    Repository
    Datadog pulumi/pulumi-datadog
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the datadog Terraform Provider.
    datadog logo
    Viewing docs for Datadog v5.12.0
    published on Friday, Sep 25, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial