1. Packages
  2. Cloudflare Provider
  3. API Docs
  4. getZoneSetting
Cloudflare v6.1.2 published on Monday, Apr 28, 2025 by Pulumi

cloudflare.getZoneSetting

Explore with Pulumi AI

cloudflare logo
Cloudflare v6.1.2 published on Monday, Apr 28, 2025 by Pulumi

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as cloudflare from "@pulumi/cloudflare";
    
    const exampleZoneSetting = cloudflare.getZoneSetting({
        zoneId: "023e105f4ecef8ad9ca31a8372d0c353",
        settingId: "always_online",
    });
    
    import pulumi
    import pulumi_cloudflare as cloudflare
    
    example_zone_setting = cloudflare.get_zone_setting(zone_id="023e105f4ecef8ad9ca31a8372d0c353",
        setting_id="always_online")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-cloudflare/sdk/v6/go/cloudflare"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudflare.LookupZoneSetting(ctx, &cloudflare.LookupZoneSettingArgs{
    			ZoneId:    "023e105f4ecef8ad9ca31a8372d0c353",
    			SettingId: "always_online",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Cloudflare = Pulumi.Cloudflare;
    
    return await Deployment.RunAsync(() => 
    {
        var exampleZoneSetting = Cloudflare.GetZoneSetting.Invoke(new()
        {
            ZoneId = "023e105f4ecef8ad9ca31a8372d0c353",
            SettingId = "always_online",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.cloudflare.CloudflareFunctions;
    import com.pulumi.cloudflare.inputs.GetZoneSettingArgs;
    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 exampleZoneSetting = CloudflareFunctions.getZoneSetting(GetZoneSettingArgs.builder()
                .zoneId("023e105f4ecef8ad9ca31a8372d0c353")
                .settingId("always_online")
                .build());
    
        }
    }
    
    variables:
      exampleZoneSetting:
        fn::invoke:
          function: cloudflare:getZoneSetting
          arguments:
            zoneId: 023e105f4ecef8ad9ca31a8372d0c353
            settingId: always_online
    

    Using getZoneSetting

    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 getZoneSetting(args: GetZoneSettingArgs, opts?: InvokeOptions): Promise<GetZoneSettingResult>
    function getZoneSettingOutput(args: GetZoneSettingOutputArgs, opts?: InvokeOptions): Output<GetZoneSettingResult>
    def get_zone_setting(setting_id: Optional[str] = None,
                         zone_id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetZoneSettingResult
    def get_zone_setting_output(setting_id: Optional[pulumi.Input[str]] = None,
                         zone_id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetZoneSettingResult]
    func LookupZoneSetting(ctx *Context, args *LookupZoneSettingArgs, opts ...InvokeOption) (*LookupZoneSettingResult, error)
    func LookupZoneSettingOutput(ctx *Context, args *LookupZoneSettingOutputArgs, opts ...InvokeOption) LookupZoneSettingResultOutput

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

    public static class GetZoneSetting 
    {
        public static Task<GetZoneSettingResult> InvokeAsync(GetZoneSettingArgs args, InvokeOptions? opts = null)
        public static Output<GetZoneSettingResult> Invoke(GetZoneSettingInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetZoneSettingResult> getZoneSetting(GetZoneSettingArgs args, InvokeOptions options)
    public static Output<GetZoneSettingResult> getZoneSetting(GetZoneSettingArgs args, InvokeOptions options)
    
    fn::invoke:
      function: cloudflare:index/getZoneSetting:getZoneSetting
      arguments:
        # arguments dictionary

    The following arguments are supported:

    SettingId string
    Setting name
    ZoneId string
    Identifier
    SettingId string
    Setting name
    ZoneId string
    Identifier
    settingId String
    Setting name
    zoneId String
    Identifier
    settingId string
    Setting name
    zoneId string
    Identifier
    setting_id str
    Setting name
    zone_id str
    Identifier
    settingId String
    Setting name
    zoneId String
    Identifier

    getZoneSetting Result

    The following output properties are available:

    Editable bool
    Whether or not this setting can be modified for this zone (based on your Cloudflare plan level).
    Enabled bool
    ssl-recommender enrollment setting.
    Id string
    ID of the zone setting. Available values: "0rtt".
    ModifiedOn string
    last time this setting was modified.
    SettingId string
    Setting name
    TimeRemaining double
    Value of the zone setting. Notes: The interval (in seconds) from when development mode expires (positive integer) or last expired (negative integer) for the domain. If development mode has never been enabled, this value is false.
    Value string
    Current value of the zone setting. Available values: "on", "off".
    ZoneId string
    Identifier
    Editable bool
    Whether or not this setting can be modified for this zone (based on your Cloudflare plan level).
    Enabled bool
    ssl-recommender enrollment setting.
    Id string
    ID of the zone setting. Available values: "0rtt".
    ModifiedOn string
    last time this setting was modified.
    SettingId string
    Setting name
    TimeRemaining float64
    Value of the zone setting. Notes: The interval (in seconds) from when development mode expires (positive integer) or last expired (negative integer) for the domain. If development mode has never been enabled, this value is false.
    Value string
    Current value of the zone setting. Available values: "on", "off".
    ZoneId string
    Identifier
    editable Boolean
    Whether or not this setting can be modified for this zone (based on your Cloudflare plan level).
    enabled Boolean
    ssl-recommender enrollment setting.
    id String
    ID of the zone setting. Available values: "0rtt".
    modifiedOn String
    last time this setting was modified.
    settingId String
    Setting name
    timeRemaining Double
    Value of the zone setting. Notes: The interval (in seconds) from when development mode expires (positive integer) or last expired (negative integer) for the domain. If development mode has never been enabled, this value is false.
    value String
    Current value of the zone setting. Available values: "on", "off".
    zoneId String
    Identifier
    editable boolean
    Whether or not this setting can be modified for this zone (based on your Cloudflare plan level).
    enabled boolean
    ssl-recommender enrollment setting.
    id string
    ID of the zone setting. Available values: "0rtt".
    modifiedOn string
    last time this setting was modified.
    settingId string
    Setting name
    timeRemaining number
    Value of the zone setting. Notes: The interval (in seconds) from when development mode expires (positive integer) or last expired (negative integer) for the domain. If development mode has never been enabled, this value is false.
    value string
    Current value of the zone setting. Available values: "on", "off".
    zoneId string
    Identifier
    editable bool
    Whether or not this setting can be modified for this zone (based on your Cloudflare plan level).
    enabled bool
    ssl-recommender enrollment setting.
    id str
    ID of the zone setting. Available values: "0rtt".
    modified_on str
    last time this setting was modified.
    setting_id str
    Setting name
    time_remaining float
    Value of the zone setting. Notes: The interval (in seconds) from when development mode expires (positive integer) or last expired (negative integer) for the domain. If development mode has never been enabled, this value is false.
    value str
    Current value of the zone setting. Available values: "on", "off".
    zone_id str
    Identifier
    editable Boolean
    Whether or not this setting can be modified for this zone (based on your Cloudflare plan level).
    enabled Boolean
    ssl-recommender enrollment setting.
    id String
    ID of the zone setting. Available values: "0rtt".
    modifiedOn String
    last time this setting was modified.
    settingId String
    Setting name
    timeRemaining Number
    Value of the zone setting. Notes: The interval (in seconds) from when development mode expires (positive integer) or last expired (negative integer) for the domain. If development mode has never been enabled, this value is false.
    value String
    Current value of the zone setting. Available values: "on", "off".
    zoneId String
    Identifier

    Package Details

    Repository
    Cloudflare pulumi/pulumi-cloudflare
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the cloudflare Terraform Provider.
    cloudflare logo
    Cloudflare v6.1.2 published on Monday, Apr 28, 2025 by Pulumi