1. Packages
  2. Cloudflare Provider
  3. API Docs
  4. ApiShieldSchemaValidationSettings
Cloudflare v6.1.1 published on Monday, Apr 21, 2025 by Pulumi

cloudflare.ApiShieldSchemaValidationSettings

Explore with Pulumi AI

Example Usage

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

const exampleApiShieldSchemaValidationSettings = new cloudflare.ApiShieldSchemaValidationSettings("example_api_shield_schema_validation_settings", {
    zoneId: "023e105f4ecef8ad9ca31a8372d0c353",
    validationDefaultMitigationAction: "block",
    validationOverrideMitigationAction: "none",
});
Copy
import pulumi
import pulumi_cloudflare as cloudflare

example_api_shield_schema_validation_settings = cloudflare.ApiShieldSchemaValidationSettings("example_api_shield_schema_validation_settings",
    zone_id="023e105f4ecef8ad9ca31a8372d0c353",
    validation_default_mitigation_action="block",
    validation_override_mitigation_action="none")
Copy
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.NewApiShieldSchemaValidationSettings(ctx, "example_api_shield_schema_validation_settings", &cloudflare.ApiShieldSchemaValidationSettingsArgs{
			ZoneId:                             pulumi.String("023e105f4ecef8ad9ca31a8372d0c353"),
			ValidationDefaultMitigationAction:  pulumi.String("block"),
			ValidationOverrideMitigationAction: pulumi.String("none"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Cloudflare = Pulumi.Cloudflare;

return await Deployment.RunAsync(() => 
{
    var exampleApiShieldSchemaValidationSettings = new Cloudflare.ApiShieldSchemaValidationSettings("example_api_shield_schema_validation_settings", new()
    {
        ZoneId = "023e105f4ecef8ad9ca31a8372d0c353",
        ValidationDefaultMitigationAction = "block",
        ValidationOverrideMitigationAction = "none",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.ApiShieldSchemaValidationSettings;
import com.pulumi.cloudflare.ApiShieldSchemaValidationSettingsArgs;
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) {
        var exampleApiShieldSchemaValidationSettings = new ApiShieldSchemaValidationSettings("exampleApiShieldSchemaValidationSettings", ApiShieldSchemaValidationSettingsArgs.builder()
            .zoneId("023e105f4ecef8ad9ca31a8372d0c353")
            .validationDefaultMitigationAction("block")
            .validationOverrideMitigationAction("none")
            .build());

    }
}
Copy
resources:
  exampleApiShieldSchemaValidationSettings:
    type: cloudflare:ApiShieldSchemaValidationSettings
    name: example_api_shield_schema_validation_settings
    properties:
      zoneId: 023e105f4ecef8ad9ca31a8372d0c353
      validationDefaultMitigationAction: block
      validationOverrideMitigationAction: none
Copy

Create ApiShieldSchemaValidationSettings Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new ApiShieldSchemaValidationSettings(name: string, args: ApiShieldSchemaValidationSettingsArgs, opts?: CustomResourceOptions);
@overload
def ApiShieldSchemaValidationSettings(resource_name: str,
                                      args: ApiShieldSchemaValidationSettingsArgs,
                                      opts: Optional[ResourceOptions] = None)

@overload
def ApiShieldSchemaValidationSettings(resource_name: str,
                                      opts: Optional[ResourceOptions] = None,
                                      validation_default_mitigation_action: Optional[str] = None,
                                      zone_id: Optional[str] = None,
                                      validation_override_mitigation_action: Optional[str] = None)
func NewApiShieldSchemaValidationSettings(ctx *Context, name string, args ApiShieldSchemaValidationSettingsArgs, opts ...ResourceOption) (*ApiShieldSchemaValidationSettings, error)
public ApiShieldSchemaValidationSettings(string name, ApiShieldSchemaValidationSettingsArgs args, CustomResourceOptions? opts = null)
public ApiShieldSchemaValidationSettings(String name, ApiShieldSchemaValidationSettingsArgs args)
public ApiShieldSchemaValidationSettings(String name, ApiShieldSchemaValidationSettingsArgs args, CustomResourceOptions options)
type: cloudflare:ApiShieldSchemaValidationSettings
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. ApiShieldSchemaValidationSettingsArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. ApiShieldSchemaValidationSettingsArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. ApiShieldSchemaValidationSettingsArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. ApiShieldSchemaValidationSettingsArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. ApiShieldSchemaValidationSettingsArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var apiShieldSchemaValidationSettingsResource = new Cloudflare.ApiShieldSchemaValidationSettings("apiShieldSchemaValidationSettingsResource", new()
{
    ValidationDefaultMitigationAction = "string",
    ZoneId = "string",
    ValidationOverrideMitigationAction = "string",
});
Copy
example, err := cloudflare.NewApiShieldSchemaValidationSettings(ctx, "apiShieldSchemaValidationSettingsResource", &cloudflare.ApiShieldSchemaValidationSettingsArgs{
	ValidationDefaultMitigationAction:  pulumi.String("string"),
	ZoneId:                             pulumi.String("string"),
	ValidationOverrideMitigationAction: pulumi.String("string"),
})
Copy
var apiShieldSchemaValidationSettingsResource = new ApiShieldSchemaValidationSettings("apiShieldSchemaValidationSettingsResource", ApiShieldSchemaValidationSettingsArgs.builder()
    .validationDefaultMitigationAction("string")
    .zoneId("string")
    .validationOverrideMitigationAction("string")
    .build());
Copy
api_shield_schema_validation_settings_resource = cloudflare.ApiShieldSchemaValidationSettings("apiShieldSchemaValidationSettingsResource",
    validation_default_mitigation_action="string",
    zone_id="string",
    validation_override_mitigation_action="string")
Copy
const apiShieldSchemaValidationSettingsResource = new cloudflare.ApiShieldSchemaValidationSettings("apiShieldSchemaValidationSettingsResource", {
    validationDefaultMitigationAction: "string",
    zoneId: "string",
    validationOverrideMitigationAction: "string",
});
Copy
type: cloudflare:ApiShieldSchemaValidationSettings
properties:
    validationDefaultMitigationAction: string
    validationOverrideMitigationAction: string
    zoneId: string
Copy

ApiShieldSchemaValidationSettings Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The ApiShieldSchemaValidationSettings resource accepts the following input properties:

ValidationDefaultMitigationAction This property is required. string
The default mitigation action used when there is no mitigation action defined on the operation
ZoneId This property is required. string
Identifier
ValidationOverrideMitigationAction string
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
ValidationDefaultMitigationAction This property is required. string
The default mitigation action used when there is no mitigation action defined on the operation
ZoneId This property is required. string
Identifier
ValidationOverrideMitigationAction string
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
validationDefaultMitigationAction This property is required. String
The default mitigation action used when there is no mitigation action defined on the operation
zoneId This property is required. String
Identifier
validationOverrideMitigationAction String
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
validationDefaultMitigationAction This property is required. string
The default mitigation action used when there is no mitigation action defined on the operation
zoneId This property is required. string
Identifier
validationOverrideMitigationAction string
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
validation_default_mitigation_action This property is required. str
The default mitigation action used when there is no mitigation action defined on the operation
zone_id This property is required. str
Identifier
validation_override_mitigation_action str
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
validationDefaultMitigationAction This property is required. String
The default mitigation action used when there is no mitigation action defined on the operation
zoneId This property is required. String
Identifier
validationOverrideMitigationAction String
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".

Outputs

All input properties are implicitly available as output properties. Additionally, the ApiShieldSchemaValidationSettings resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing ApiShieldSchemaValidationSettings Resource

Get an existing ApiShieldSchemaValidationSettings resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: ApiShieldSchemaValidationSettingsState, opts?: CustomResourceOptions): ApiShieldSchemaValidationSettings
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        validation_default_mitigation_action: Optional[str] = None,
        validation_override_mitigation_action: Optional[str] = None,
        zone_id: Optional[str] = None) -> ApiShieldSchemaValidationSettings
func GetApiShieldSchemaValidationSettings(ctx *Context, name string, id IDInput, state *ApiShieldSchemaValidationSettingsState, opts ...ResourceOption) (*ApiShieldSchemaValidationSettings, error)
public static ApiShieldSchemaValidationSettings Get(string name, Input<string> id, ApiShieldSchemaValidationSettingsState? state, CustomResourceOptions? opts = null)
public static ApiShieldSchemaValidationSettings get(String name, Output<String> id, ApiShieldSchemaValidationSettingsState state, CustomResourceOptions options)
resources:  _:    type: cloudflare:ApiShieldSchemaValidationSettings    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
ValidationDefaultMitigationAction string
The default mitigation action used when there is no mitigation action defined on the operation
ValidationOverrideMitigationAction string
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
ZoneId string
Identifier
ValidationDefaultMitigationAction string
The default mitigation action used when there is no mitigation action defined on the operation
ValidationOverrideMitigationAction string
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
ZoneId string
Identifier
validationDefaultMitigationAction String
The default mitigation action used when there is no mitigation action defined on the operation
validationOverrideMitigationAction String
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
zoneId String
Identifier
validationDefaultMitigationAction string
The default mitigation action used when there is no mitigation action defined on the operation
validationOverrideMitigationAction string
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
zoneId string
Identifier
validation_default_mitigation_action str
The default mitigation action used when there is no mitigation action defined on the operation
validation_override_mitigation_action str
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
zone_id str
Identifier
validationDefaultMitigationAction String
The default mitigation action used when there is no mitigation action defined on the operation
validationOverrideMitigationAction String
When set, this overrides both zone level and operation level mitigation actions. - none will skip running schema validation entirely for the request - null indicates that no override is in place To clear any override, use the special value disable_override or null Available values: "none", "disable_override".
zoneId String
Identifier

Import

$ pulumi import cloudflare:index/apiShieldSchemaValidationSettings:ApiShieldSchemaValidationSettings example '<zone_id>'
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Cloudflare pulumi/pulumi-cloudflare
License
Apache-2.0
Notes
This Pulumi package is based on the cloudflare Terraform Provider.