1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. WafProtectionMode
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.WafProtectionMode

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Provides a resource to create a waf protection_mode

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const example = new tencentcloud.WafProtectionMode("example", {
        domain: "keep.qcloudwaf.com",
        edition: "sparta-waf",
        mode: 10,
        type: 0,
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    example = tencentcloud.WafProtectionMode("example",
        domain="keep.qcloudwaf.com",
        edition="sparta-waf",
        mode=10,
        type=0)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewWafProtectionMode(ctx, "example", &tencentcloud.WafProtectionModeArgs{
    			Domain:  pulumi.String("keep.qcloudwaf.com"),
    			Edition: pulumi.String("sparta-waf"),
    			Mode:    pulumi.Float64(10),
    			Type:    pulumi.Float64(0),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Tencentcloud.WafProtectionMode("example", new()
        {
            Domain = "keep.qcloudwaf.com",
            Edition = "sparta-waf",
            Mode = 10,
            Type = 0,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.WafProtectionMode;
    import com.pulumi.tencentcloud.WafProtectionModeArgs;
    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 example = new WafProtectionMode("example", WafProtectionModeArgs.builder()
                .domain("keep.qcloudwaf.com")
                .edition("sparta-waf")
                .mode(10)
                .type(0)
                .build());
    
        }
    }
    
    resources:
      example:
        type: tencentcloud:WafProtectionMode
        properties:
          domain: keep.qcloudwaf.com
          edition: sparta-waf
          mode: 10
          type: 0
    

    Create WafProtectionMode Resource

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

    Constructor syntax

    new WafProtectionMode(name: string, args: WafProtectionModeArgs, opts?: CustomResourceOptions);
    @overload
    def WafProtectionMode(resource_name: str,
                          args: WafProtectionModeArgs,
                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def WafProtectionMode(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          domain: Optional[str] = None,
                          mode: Optional[float] = None,
                          edition: Optional[str] = None,
                          type: Optional[float] = None,
                          waf_protection_mode_id: Optional[str] = None)
    func NewWafProtectionMode(ctx *Context, name string, args WafProtectionModeArgs, opts ...ResourceOption) (*WafProtectionMode, error)
    public WafProtectionMode(string name, WafProtectionModeArgs args, CustomResourceOptions? opts = null)
    public WafProtectionMode(String name, WafProtectionModeArgs args)
    public WafProtectionMode(String name, WafProtectionModeArgs args, CustomResourceOptions options)
    
    type: tencentcloud:WafProtectionMode
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

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

    WafProtectionMode 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 WafProtectionMode resource accepts the following input properties:

    Domain string
    Domain.
    Mode double
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    Edition string
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    Type double
    0 is to modify the rule engine status, 1 is to modify the AI status.
    WafProtectionModeId string
    ID of the resource.
    Domain string
    Domain.
    Mode float64
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    Edition string
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    Type float64
    0 is to modify the rule engine status, 1 is to modify the AI status.
    WafProtectionModeId string
    ID of the resource.
    domain String
    Domain.
    mode Double
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    edition String
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    type Double
    0 is to modify the rule engine status, 1 is to modify the AI status.
    wafProtectionModeId String
    ID of the resource.
    domain string
    Domain.
    mode number
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    edition string
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    type number
    0 is to modify the rule engine status, 1 is to modify the AI status.
    wafProtectionModeId string
    ID of the resource.
    domain str
    Domain.
    mode float
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    edition str
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    type float
    0 is to modify the rule engine status, 1 is to modify the AI status.
    waf_protection_mode_id str
    ID of the resource.
    domain String
    Domain.
    mode Number
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    edition String
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    type Number
    0 is to modify the rule engine status, 1 is to modify the AI status.
    wafProtectionModeId String
    ID of the resource.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the WafProtectionMode 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 WafProtectionMode Resource

    Get an existing WafProtectionMode 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?: WafProtectionModeState, opts?: CustomResourceOptions): WafProtectionMode
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            domain: Optional[str] = None,
            edition: Optional[str] = None,
            mode: Optional[float] = None,
            type: Optional[float] = None,
            waf_protection_mode_id: Optional[str] = None) -> WafProtectionMode
    func GetWafProtectionMode(ctx *Context, name string, id IDInput, state *WafProtectionModeState, opts ...ResourceOption) (*WafProtectionMode, error)
    public static WafProtectionMode Get(string name, Input<string> id, WafProtectionModeState? state, CustomResourceOptions? opts = null)
    public static WafProtectionMode get(String name, Output<String> id, WafProtectionModeState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:WafProtectionMode    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    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:
    Domain string
    Domain.
    Edition string
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    Mode double
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    Type double
    0 is to modify the rule engine status, 1 is to modify the AI status.
    WafProtectionModeId string
    ID of the resource.
    Domain string
    Domain.
    Edition string
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    Mode float64
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    Type float64
    0 is to modify the rule engine status, 1 is to modify the AI status.
    WafProtectionModeId string
    ID of the resource.
    domain String
    Domain.
    edition String
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    mode Double
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    type Double
    0 is to modify the rule engine status, 1 is to modify the AI status.
    wafProtectionModeId String
    ID of the resource.
    domain string
    Domain.
    edition string
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    mode number
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    type number
    0 is to modify the rule engine status, 1 is to modify the AI status.
    wafProtectionModeId string
    ID of the resource.
    domain str
    Domain.
    edition str
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    mode float
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    type float
    0 is to modify the rule engine status, 1 is to modify the AI status.
    waf_protection_mode_id str
    ID of the resource.
    domain String
    Domain.
    edition String
    WAF edition. clb-waf means clb-waf, sparta-waf means saas-waf, default is sparta-waf.
    mode Number
    Protection status:10: Rule observation; AI off mode, 11: Rule observation; AI observation mode, 12: Rule observation; AI interception mode20: Rule interception; AI off mode, 21: Rule interception; AI observation mode, 22: Rule interception; AI interception mode.
    type Number
    0 is to modify the rule engine status, 1 is to modify the AI status.
    wafProtectionModeId String
    ID of the resource.

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    tencentcloud logo
    tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack