1. Packages
  2. Volcengine
  3. API Docs
  4. waf
  5. CustomPage
Volcengine v0.0.34 published on Wednesday, Jul 2, 2025 by Volcengine

volcengine.waf.CustomPage

Explore with Pulumi AI

volcengine logo
Volcengine v0.0.34 published on Wednesday, Jul 2, 2025 by Volcengine

    Provides a resource to manage waf custom page

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as volcengine from "@volcengine/pulumi";
    
    const foo = new volcengine.waf.CustomPage("foo", {
        accurate: {
            accurateRules: [
                {
                    httpObj: "request.uri",
                    objType: 1,
                    opretar: 2,
                    property: 0,
                    valueString: "tf",
                },
                {
                    httpObj: "request.schema",
                    objType: 0,
                    opretar: 2,
                    property: 0,
                    valueString: "tf-2",
                },
            ],
            logic: 2,
        },
        advanced: 1,
        body: "tf-test-body",
        clientIp: "ALL",
        code: 403,
        contentType: "text/html",
        description: "tf-test",
        enable: 1,
        host: "www.123.com",
        pageMode: 1,
        policy: 1,
        projectName: "default",
        redirectUrl: "/test/tf/path",
        url: "/tf-test",
    });
    
    import pulumi
    import pulumi_volcengine as volcengine
    
    foo = volcengine.waf.CustomPage("foo",
        accurate=volcengine.waf.CustomPageAccurateArgs(
            accurate_rules=[
                volcengine.waf.CustomPageAccurateAccurateRuleArgs(
                    http_obj="request.uri",
                    obj_type=1,
                    opretar=2,
                    property=0,
                    value_string="tf",
                ),
                volcengine.waf.CustomPageAccurateAccurateRuleArgs(
                    http_obj="request.schema",
                    obj_type=0,
                    opretar=2,
                    property=0,
                    value_string="tf-2",
                ),
            ],
            logic=2,
        ),
        advanced=1,
        body="tf-test-body",
        client_ip="ALL",
        code=403,
        content_type="text/html",
        description="tf-test",
        enable=1,
        host="www.123.com",
        page_mode=1,
        policy=1,
        project_name="default",
        redirect_url="/test/tf/path",
        url="/tf-test")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/waf"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := waf.NewCustomPage(ctx, "foo", &waf.CustomPageArgs{
    			Accurate: &waf.CustomPageAccurateArgs{
    				AccurateRules: waf.CustomPageAccurateAccurateRuleArray{
    					&waf.CustomPageAccurateAccurateRuleArgs{
    						HttpObj:     pulumi.String("request.uri"),
    						ObjType:     pulumi.Int(1),
    						Opretar:     pulumi.Int(2),
    						Property:    pulumi.Int(0),
    						ValueString: pulumi.String("tf"),
    					},
    					&waf.CustomPageAccurateAccurateRuleArgs{
    						HttpObj:     pulumi.String("request.schema"),
    						ObjType:     pulumi.Int(0),
    						Opretar:     pulumi.Int(2),
    						Property:    pulumi.Int(0),
    						ValueString: pulumi.String("tf-2"),
    					},
    				},
    				Logic: pulumi.Int(2),
    			},
    			Advanced:    pulumi.Int(1),
    			Body:        pulumi.String("tf-test-body"),
    			ClientIp:    pulumi.String("ALL"),
    			Code:        pulumi.Int(403),
    			ContentType: pulumi.String("text/html"),
    			Description: pulumi.String("tf-test"),
    			Enable:      pulumi.Int(1),
    			Host:        pulumi.String("www.123.com"),
    			PageMode:    pulumi.Int(1),
    			Policy:      pulumi.Int(1),
    			ProjectName: pulumi.String("default"),
    			RedirectUrl: pulumi.String("/test/tf/path"),
    			Url:         pulumi.String("/tf-test"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Volcengine = Pulumi.Volcengine;
    
    return await Deployment.RunAsync(() => 
    {
        var foo = new Volcengine.Waf.CustomPage("foo", new()
        {
            Accurate = new Volcengine.Waf.Inputs.CustomPageAccurateArgs
            {
                AccurateRules = new[]
                {
                    new Volcengine.Waf.Inputs.CustomPageAccurateAccurateRuleArgs
                    {
                        HttpObj = "request.uri",
                        ObjType = 1,
                        Opretar = 2,
                        Property = 0,
                        ValueString = "tf",
                    },
                    new Volcengine.Waf.Inputs.CustomPageAccurateAccurateRuleArgs
                    {
                        HttpObj = "request.schema",
                        ObjType = 0,
                        Opretar = 2,
                        Property = 0,
                        ValueString = "tf-2",
                    },
                },
                Logic = 2,
            },
            Advanced = 1,
            Body = "tf-test-body",
            ClientIp = "ALL",
            Code = 403,
            ContentType = "text/html",
            Description = "tf-test",
            Enable = 1,
            Host = "www.123.com",
            PageMode = 1,
            Policy = 1,
            ProjectName = "default",
            RedirectUrl = "/test/tf/path",
            Url = "/tf-test",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.volcengine.waf.CustomPage;
    import com.pulumi.volcengine.waf.CustomPageArgs;
    import com.pulumi.volcengine.waf.inputs.CustomPageAccurateArgs;
    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 foo = new CustomPage("foo", CustomPageArgs.builder()        
                .accurate(CustomPageAccurateArgs.builder()
                    .accurateRules(                
                        CustomPageAccurateAccurateRuleArgs.builder()
                            .httpObj("request.uri")
                            .objType(1)
                            .opretar(2)
                            .property(0)
                            .valueString("tf")
                            .build(),
                        CustomPageAccurateAccurateRuleArgs.builder()
                            .httpObj("request.schema")
                            .objType(0)
                            .opretar(2)
                            .property(0)
                            .valueString("tf-2")
                            .build())
                    .logic(2)
                    .build())
                .advanced(1)
                .body("tf-test-body")
                .clientIp("ALL")
                .code(403)
                .contentType("text/html")
                .description("tf-test")
                .enable(1)
                .host("www.123.com")
                .pageMode(1)
                .policy(1)
                .projectName("default")
                .redirectUrl("/test/tf/path")
                .url("/tf-test")
                .build());
    
        }
    }
    
    resources:
      foo:
        type: volcengine:waf:CustomPage
        properties:
          accurate:
            accurateRules:
              - httpObj: request.uri
                objType: 1
                opretar: 2
                property: 0
                valueString: tf
              - httpObj: request.schema
                objType: 0
                opretar: 2
                property: 0
                valueString: tf-2
            logic: 2
          advanced: 1
          body: tf-test-body
          clientIp: ALL
          code: 403
          contentType: text/html
          description: tf-test
          enable: 1
          host: www.123.com
          pageMode: 1
          policy: 1
          projectName: default
          redirectUrl: /test/tf/path
          url: /tf-test
    

    Create CustomPage Resource

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

    Constructor syntax

    new CustomPage(name: string, args: CustomPageArgs, opts?: CustomResourceOptions);
    @overload
    def CustomPage(resource_name: str,
                   args: CustomPageArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def CustomPage(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   enable: Optional[int] = None,
                   url: Optional[str] = None,
                   policy: Optional[int] = None,
                   client_ip: Optional[str] = None,
                   code: Optional[int] = None,
                   page_mode: Optional[int] = None,
                   host: Optional[str] = None,
                   description: Optional[str] = None,
                   accurate: Optional[CustomPageAccurateArgs] = None,
                   name: Optional[str] = None,
                   content_type: Optional[str] = None,
                   body: Optional[str] = None,
                   project_name: Optional[str] = None,
                   redirect_url: Optional[str] = None,
                   advanced: Optional[int] = None)
    func NewCustomPage(ctx *Context, name string, args CustomPageArgs, opts ...ResourceOption) (*CustomPage, error)
    public CustomPage(string name, CustomPageArgs args, CustomResourceOptions? opts = null)
    public CustomPage(String name, CustomPageArgs args)
    public CustomPage(String name, CustomPageArgs args, CustomResourceOptions options)
    
    type: volcengine:waf:CustomPage
    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 CustomPageArgs
    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 CustomPageArgs
    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 CustomPageArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args CustomPageArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args CustomPageArgs
    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 customPageResource = new Volcengine.Waf.CustomPage("customPageResource", new()
    {
        Enable = 0,
        Url = "string",
        Policy = 0,
        ClientIp = "string",
        Code = 0,
        PageMode = 0,
        Host = "string",
        Description = "string",
        Accurate = new Volcengine.Waf.Inputs.CustomPageAccurateArgs
        {
            AccurateRules = new[]
            {
                new Volcengine.Waf.Inputs.CustomPageAccurateAccurateRuleArgs
                {
                    HttpObj = "string",
                    ObjType = 0,
                    Opretar = 0,
                    Property = 0,
                    ValueString = "string",
                },
            },
            Logic = 0,
        },
        Name = "string",
        ContentType = "string",
        Body = "string",
        ProjectName = "string",
        RedirectUrl = "string",
        Advanced = 0,
    });
    
    example, err := waf.NewCustomPage(ctx, "customPageResource", &waf.CustomPageArgs{
    	Enable:      pulumi.Int(0),
    	Url:         pulumi.String("string"),
    	Policy:      pulumi.Int(0),
    	ClientIp:    pulumi.String("string"),
    	Code:        pulumi.Int(0),
    	PageMode:    pulumi.Int(0),
    	Host:        pulumi.String("string"),
    	Description: pulumi.String("string"),
    	Accurate: &waf.CustomPageAccurateArgs{
    		AccurateRules: waf.CustomPageAccurateAccurateRuleArray{
    			&waf.CustomPageAccurateAccurateRuleArgs{
    				HttpObj:     pulumi.String("string"),
    				ObjType:     pulumi.Int(0),
    				Opretar:     pulumi.Int(0),
    				Property:    pulumi.Int(0),
    				ValueString: pulumi.String("string"),
    			},
    		},
    		Logic: pulumi.Int(0),
    	},
    	Name:        pulumi.String("string"),
    	ContentType: pulumi.String("string"),
    	Body:        pulumi.String("string"),
    	ProjectName: pulumi.String("string"),
    	RedirectUrl: pulumi.String("string"),
    	Advanced:    pulumi.Int(0),
    })
    
    var customPageResource = new CustomPage("customPageResource", CustomPageArgs.builder()
        .enable(0)
        .url("string")
        .policy(0)
        .clientIp("string")
        .code(0)
        .pageMode(0)
        .host("string")
        .description("string")
        .accurate(CustomPageAccurateArgs.builder()
            .accurateRules(CustomPageAccurateAccurateRuleArgs.builder()
                .httpObj("string")
                .objType(0)
                .opretar(0)
                .property(0)
                .valueString("string")
                .build())
            .logic(0)
            .build())
        .name("string")
        .contentType("string")
        .body("string")
        .projectName("string")
        .redirectUrl("string")
        .advanced(0)
        .build());
    
    custom_page_resource = volcengine.waf.CustomPage("customPageResource",
        enable=0,
        url="string",
        policy=0,
        client_ip="string",
        code=0,
        page_mode=0,
        host="string",
        description="string",
        accurate={
            "accurate_rules": [{
                "http_obj": "string",
                "obj_type": 0,
                "opretar": 0,
                "property": 0,
                "value_string": "string",
            }],
            "logic": 0,
        },
        name="string",
        content_type="string",
        body="string",
        project_name="string",
        redirect_url="string",
        advanced=0)
    
    const customPageResource = new volcengine.waf.CustomPage("customPageResource", {
        enable: 0,
        url: "string",
        policy: 0,
        clientIp: "string",
        code: 0,
        pageMode: 0,
        host: "string",
        description: "string",
        accurate: {
            accurateRules: [{
                httpObj: "string",
                objType: 0,
                opretar: 0,
                property: 0,
                valueString: "string",
            }],
            logic: 0,
        },
        name: "string",
        contentType: "string",
        body: "string",
        projectName: "string",
        redirectUrl: "string",
        advanced: 0,
    });
    
    type: volcengine:waf:CustomPage
    properties:
        accurate:
            accurateRules:
                - httpObj: string
                  objType: 0
                  opretar: 0
                  property: 0
                  valueString: string
            logic: 0
        advanced: 0
        body: string
        clientIp: string
        code: 0
        contentType: string
        description: string
        enable: 0
        host: string
        name: string
        pageMode: 0
        policy: 0
        projectName: string
        redirectUrl: string
        url: string
    

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

    ClientIp string
    Fill in ALL, which means this rule will take effect on all IP addresses.
    Code int
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    Enable int
    Whether to enable the rule.
    Host string
    Domain name to be protected.
    PageMode int
    The layout template of the response page.
    Policy int
    Action to be taken on requests that match the rule.
    Url string
    Match the path.
    Accurate CustomPageAccurate
    Advanced conditions.
    Advanced int
    Whether to configure advanced conditions.
    Body string
    The layout content of the response page.
    ContentType string
    The layout template of the response page. Required if PageMode=0 or 1.
    Description string
    Rule description.
    Name string
    Rule name.
    ProjectName string
    The name of the project to which your domain names belong.
    RedirectUrl string
    The path where users should be redirected.
    ClientIp string
    Fill in ALL, which means this rule will take effect on all IP addresses.
    Code int
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    Enable int
    Whether to enable the rule.
    Host string
    Domain name to be protected.
    PageMode int
    The layout template of the response page.
    Policy int
    Action to be taken on requests that match the rule.
    Url string
    Match the path.
    Accurate CustomPageAccurateArgs
    Advanced conditions.
    Advanced int
    Whether to configure advanced conditions.
    Body string
    The layout content of the response page.
    ContentType string
    The layout template of the response page. Required if PageMode=0 or 1.
    Description string
    Rule description.
    Name string
    Rule name.
    ProjectName string
    The name of the project to which your domain names belong.
    RedirectUrl string
    The path where users should be redirected.
    clientIp String
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code Integer
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    enable Integer
    Whether to enable the rule.
    host String
    Domain name to be protected.
    pageMode Integer
    The layout template of the response page.
    policy Integer
    Action to be taken on requests that match the rule.
    url String
    Match the path.
    accurate CustomPageAccurate
    Advanced conditions.
    advanced Integer
    Whether to configure advanced conditions.
    body String
    The layout content of the response page.
    contentType String
    The layout template of the response page. Required if PageMode=0 or 1.
    description String
    Rule description.
    name String
    Rule name.
    projectName String
    The name of the project to which your domain names belong.
    redirectUrl String
    The path where users should be redirected.
    clientIp string
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code number
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    enable number
    Whether to enable the rule.
    host string
    Domain name to be protected.
    pageMode number
    The layout template of the response page.
    policy number
    Action to be taken on requests that match the rule.
    url string
    Match the path.
    accurate CustomPageAccurate
    Advanced conditions.
    advanced number
    Whether to configure advanced conditions.
    body string
    The layout content of the response page.
    contentType string
    The layout template of the response page. Required if PageMode=0 or 1.
    description string
    Rule description.
    name string
    Rule name.
    projectName string
    The name of the project to which your domain names belong.
    redirectUrl string
    The path where users should be redirected.
    client_ip str
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code int
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    enable int
    Whether to enable the rule.
    host str
    Domain name to be protected.
    page_mode int
    The layout template of the response page.
    policy int
    Action to be taken on requests that match the rule.
    url str
    Match the path.
    accurate CustomPageAccurateArgs
    Advanced conditions.
    advanced int
    Whether to configure advanced conditions.
    body str
    The layout content of the response page.
    content_type str
    The layout template of the response page. Required if PageMode=0 or 1.
    description str
    Rule description.
    name str
    Rule name.
    project_name str
    The name of the project to which your domain names belong.
    redirect_url str
    The path where users should be redirected.
    clientIp String
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code Number
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    enable Number
    Whether to enable the rule.
    host String
    Domain name to be protected.
    pageMode Number
    The layout template of the response page.
    policy Number
    Action to be taken on requests that match the rule.
    url String
    Match the path.
    accurate Property Map
    Advanced conditions.
    advanced Number
    Whether to configure advanced conditions.
    body String
    The layout content of the response page.
    contentType String
    The layout template of the response page. Required if PageMode=0 or 1.
    description String
    Rule description.
    name String
    Rule name.
    projectName String
    The name of the project to which your domain names belong.
    redirectUrl String
    The path where users should be redirected.

    Outputs

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

    GroupId int
    The ID of the advanced conditional rule group.
    Header string
    Request header information.
    Id string
    The provider-assigned unique ID for this managed resource.
    IsolationId string
    The ID of Region.
    RuleTag string
    Unique identification of the rules.
    UpdateTime string
    Rule update time.
    GroupId int
    The ID of the advanced conditional rule group.
    Header string
    Request header information.
    Id string
    The provider-assigned unique ID for this managed resource.
    IsolationId string
    The ID of Region.
    RuleTag string
    Unique identification of the rules.
    UpdateTime string
    Rule update time.
    groupId Integer
    The ID of the advanced conditional rule group.
    header String
    Request header information.
    id String
    The provider-assigned unique ID for this managed resource.
    isolationId String
    The ID of Region.
    ruleTag String
    Unique identification of the rules.
    updateTime String
    Rule update time.
    groupId number
    The ID of the advanced conditional rule group.
    header string
    Request header information.
    id string
    The provider-assigned unique ID for this managed resource.
    isolationId string
    The ID of Region.
    ruleTag string
    Unique identification of the rules.
    updateTime string
    Rule update time.
    group_id int
    The ID of the advanced conditional rule group.
    header str
    Request header information.
    id str
    The provider-assigned unique ID for this managed resource.
    isolation_id str
    The ID of Region.
    rule_tag str
    Unique identification of the rules.
    update_time str
    Rule update time.
    groupId Number
    The ID of the advanced conditional rule group.
    header String
    Request header information.
    id String
    The provider-assigned unique ID for this managed resource.
    isolationId String
    The ID of Region.
    ruleTag String
    Unique identification of the rules.
    updateTime String
    Rule update time.

    Look up Existing CustomPage Resource

    Get an existing CustomPage 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?: CustomPageState, opts?: CustomResourceOptions): CustomPage
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            accurate: Optional[CustomPageAccurateArgs] = None,
            advanced: Optional[int] = None,
            body: Optional[str] = None,
            client_ip: Optional[str] = None,
            code: Optional[int] = None,
            content_type: Optional[str] = None,
            description: Optional[str] = None,
            enable: Optional[int] = None,
            group_id: Optional[int] = None,
            header: Optional[str] = None,
            host: Optional[str] = None,
            isolation_id: Optional[str] = None,
            name: Optional[str] = None,
            page_mode: Optional[int] = None,
            policy: Optional[int] = None,
            project_name: Optional[str] = None,
            redirect_url: Optional[str] = None,
            rule_tag: Optional[str] = None,
            update_time: Optional[str] = None,
            url: Optional[str] = None) -> CustomPage
    func GetCustomPage(ctx *Context, name string, id IDInput, state *CustomPageState, opts ...ResourceOption) (*CustomPage, error)
    public static CustomPage Get(string name, Input<string> id, CustomPageState? state, CustomResourceOptions? opts = null)
    public static CustomPage get(String name, Output<String> id, CustomPageState state, CustomResourceOptions options)
    resources:  _:    type: volcengine:waf:CustomPage    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:
    Accurate CustomPageAccurate
    Advanced conditions.
    Advanced int
    Whether to configure advanced conditions.
    Body string
    The layout content of the response page.
    ClientIp string
    Fill in ALL, which means this rule will take effect on all IP addresses.
    Code int
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    ContentType string
    The layout template of the response page. Required if PageMode=0 or 1.
    Description string
    Rule description.
    Enable int
    Whether to enable the rule.
    GroupId int
    The ID of the advanced conditional rule group.
    Header string
    Request header information.
    Host string
    Domain name to be protected.
    IsolationId string
    The ID of Region.
    Name string
    Rule name.
    PageMode int
    The layout template of the response page.
    Policy int
    Action to be taken on requests that match the rule.
    ProjectName string
    The name of the project to which your domain names belong.
    RedirectUrl string
    The path where users should be redirected.
    RuleTag string
    Unique identification of the rules.
    UpdateTime string
    Rule update time.
    Url string
    Match the path.
    Accurate CustomPageAccurateArgs
    Advanced conditions.
    Advanced int
    Whether to configure advanced conditions.
    Body string
    The layout content of the response page.
    ClientIp string
    Fill in ALL, which means this rule will take effect on all IP addresses.
    Code int
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    ContentType string
    The layout template of the response page. Required if PageMode=0 or 1.
    Description string
    Rule description.
    Enable int
    Whether to enable the rule.
    GroupId int
    The ID of the advanced conditional rule group.
    Header string
    Request header information.
    Host string
    Domain name to be protected.
    IsolationId string
    The ID of Region.
    Name string
    Rule name.
    PageMode int
    The layout template of the response page.
    Policy int
    Action to be taken on requests that match the rule.
    ProjectName string
    The name of the project to which your domain names belong.
    RedirectUrl string
    The path where users should be redirected.
    RuleTag string
    Unique identification of the rules.
    UpdateTime string
    Rule update time.
    Url string
    Match the path.
    accurate CustomPageAccurate
    Advanced conditions.
    advanced Integer
    Whether to configure advanced conditions.
    body String
    The layout content of the response page.
    clientIp String
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code Integer
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    contentType String
    The layout template of the response page. Required if PageMode=0 or 1.
    description String
    Rule description.
    enable Integer
    Whether to enable the rule.
    groupId Integer
    The ID of the advanced conditional rule group.
    header String
    Request header information.
    host String
    Domain name to be protected.
    isolationId String
    The ID of Region.
    name String
    Rule name.
    pageMode Integer
    The layout template of the response page.
    policy Integer
    Action to be taken on requests that match the rule.
    projectName String
    The name of the project to which your domain names belong.
    redirectUrl String
    The path where users should be redirected.
    ruleTag String
    Unique identification of the rules.
    updateTime String
    Rule update time.
    url String
    Match the path.
    accurate CustomPageAccurate
    Advanced conditions.
    advanced number
    Whether to configure advanced conditions.
    body string
    The layout content of the response page.
    clientIp string
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code number
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    contentType string
    The layout template of the response page. Required if PageMode=0 or 1.
    description string
    Rule description.
    enable number
    Whether to enable the rule.
    groupId number
    The ID of the advanced conditional rule group.
    header string
    Request header information.
    host string
    Domain name to be protected.
    isolationId string
    The ID of Region.
    name string
    Rule name.
    pageMode number
    The layout template of the response page.
    policy number
    Action to be taken on requests that match the rule.
    projectName string
    The name of the project to which your domain names belong.
    redirectUrl string
    The path where users should be redirected.
    ruleTag string
    Unique identification of the rules.
    updateTime string
    Rule update time.
    url string
    Match the path.
    accurate CustomPageAccurateArgs
    Advanced conditions.
    advanced int
    Whether to configure advanced conditions.
    body str
    The layout content of the response page.
    client_ip str
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code int
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    content_type str
    The layout template of the response page. Required if PageMode=0 or 1.
    description str
    Rule description.
    enable int
    Whether to enable the rule.
    group_id int
    The ID of the advanced conditional rule group.
    header str
    Request header information.
    host str
    Domain name to be protected.
    isolation_id str
    The ID of Region.
    name str
    Rule name.
    page_mode int
    The layout template of the response page.
    policy int
    Action to be taken on requests that match the rule.
    project_name str
    The name of the project to which your domain names belong.
    redirect_url str
    The path where users should be redirected.
    rule_tag str
    Unique identification of the rules.
    update_time str
    Rule update time.
    url str
    Match the path.
    accurate Property Map
    Advanced conditions.
    advanced Number
    Whether to configure advanced conditions.
    body String
    The layout content of the response page.
    clientIp String
    Fill in ALL, which means this rule will take effect on all IP addresses.
    code Number
    Custom HTTP code returned when the request is blocked. Required if PageMode=0 or 1.
    contentType String
    The layout template of the response page. Required if PageMode=0 or 1.
    description String
    Rule description.
    enable Number
    Whether to enable the rule.
    groupId Number
    The ID of the advanced conditional rule group.
    header String
    Request header information.
    host String
    Domain name to be protected.
    isolationId String
    The ID of Region.
    name String
    Rule name.
    pageMode Number
    The layout template of the response page.
    policy Number
    Action to be taken on requests that match the rule.
    projectName String
    The name of the project to which your domain names belong.
    redirectUrl String
    The path where users should be redirected.
    ruleTag String
    Unique identification of the rules.
    updateTime String
    Rule update time.
    url String
    Match the path.

    Supporting Types

    CustomPageAccurate, CustomPageAccurateArgs

    AccurateRules List<CustomPageAccurateAccurateRule>
    Details of advanced conditions.
    Logic int
    The logical relationship of advanced conditions.
    AccurateRules []CustomPageAccurateAccurateRule
    Details of advanced conditions.
    Logic int
    The logical relationship of advanced conditions.
    accurateRules List<CustomPageAccurateAccurateRule>
    Details of advanced conditions.
    logic Integer
    The logical relationship of advanced conditions.
    accurateRules CustomPageAccurateAccurateRule[]
    Details of advanced conditions.
    logic number
    The logical relationship of advanced conditions.
    accurate_rules Sequence[CustomPageAccurateAccurateRule]
    Details of advanced conditions.
    logic int
    The logical relationship of advanced conditions.
    accurateRules List<Property Map>
    Details of advanced conditions.
    logic Number
    The logical relationship of advanced conditions.

    CustomPageAccurateAccurateRule, CustomPageAccurateAccurateRuleArgs

    HttpObj string
    The HTTP object to be added to the advanced conditions.
    ObjType int
    The matching field for HTTP objects.
    Opretar int
    The logical operator for the condition.
    Property int
    Operate the properties of the http object.
    ValueString string
    The value to be matched.
    HttpObj string
    The HTTP object to be added to the advanced conditions.
    ObjType int
    The matching field for HTTP objects.
    Opretar int
    The logical operator for the condition.
    Property int
    Operate the properties of the http object.
    ValueString string
    The value to be matched.
    httpObj String
    The HTTP object to be added to the advanced conditions.
    objType Integer
    The matching field for HTTP objects.
    opretar Integer
    The logical operator for the condition.
    property Integer
    Operate the properties of the http object.
    valueString String
    The value to be matched.
    httpObj string
    The HTTP object to be added to the advanced conditions.
    objType number
    The matching field for HTTP objects.
    opretar number
    The logical operator for the condition.
    property number
    Operate the properties of the http object.
    valueString string
    The value to be matched.
    http_obj str
    The HTTP object to be added to the advanced conditions.
    obj_type int
    The matching field for HTTP objects.
    opretar int
    The logical operator for the condition.
    property int
    Operate the properties of the http object.
    value_string str
    The value to be matched.
    httpObj String
    The HTTP object to be added to the advanced conditions.
    objType Number
    The matching field for HTTP objects.
    opretar Number
    The logical operator for the condition.
    property Number
    Operate the properties of the http object.
    valueString String
    The value to be matched.

    Import

    WafCustomPage can be imported using the id, e.g.

    $ pulumi import volcengine:waf/customPage:CustomPage default resource_id:Host
    

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

    Package Details

    Repository
    volcengine volcengine/pulumi-volcengine
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the volcengine Terraform Provider.
    volcengine logo
    Volcengine v0.0.34 published on Wednesday, Jul 2, 2025 by Volcengine