1. Packages
  2. Fastly Provider
  3. API Docs
  4. NgwafWorkspaceSignal
Fastly v11.0.0 published on Thursday, Sep 4, 2025 by Pulumi

fastly.NgwafWorkspaceSignal

Explore with Pulumi AI

fastly logo
Fastly v11.0.0 published on Thursday, Sep 4, 2025 by Pulumi

    Provides a Fastly Next-Gen WAF Workspace Signal, scoped to a specific NGWAF workspace.
    These signals define conditions and actions that trigger WAF enforcement at the workspace level.

    Example Usage

    Basic usage:

    import * as pulumi from "@pulumi/pulumi";
    import * as fastly from "@pulumi/fastly";
    
    const example = new fastly.NgwafWorkspace("example", {
        name: "example",
        description: "Test NGWAF Workspace",
        mode: "block",
        ipAnonymization: "hashed",
        clientIpHeaders: [
            "X-Forwarded-For",
            "X-Real-IP",
        ],
        defaultBlockingResponseCode: 429,
        attackSignalThresholds: {},
    });
    const exampleNgwafWorkspaceSignal = new fastly.NgwafWorkspaceSignal("example", {
        workspaceId: example.id,
        description: "example",
        name: "Test Name",
    });
    
    import pulumi
    import pulumi_fastly as fastly
    
    example = fastly.NgwafWorkspace("example",
        name="example",
        description="Test NGWAF Workspace",
        mode="block",
        ip_anonymization="hashed",
        client_ip_headers=[
            "X-Forwarded-For",
            "X-Real-IP",
        ],
        default_blocking_response_code=429,
        attack_signal_thresholds={})
    example_ngwaf_workspace_signal = fastly.NgwafWorkspaceSignal("example",
        workspace_id=example.id,
        description="example",
        name="Test Name")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-fastly/sdk/v11/go/fastly"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := fastly.NewNgwafWorkspace(ctx, "example", &fastly.NgwafWorkspaceArgs{
    			Name:            pulumi.String("example"),
    			Description:     pulumi.String("Test NGWAF Workspace"),
    			Mode:            pulumi.String("block"),
    			IpAnonymization: pulumi.String("hashed"),
    			ClientIpHeaders: pulumi.StringArray{
    				pulumi.String("X-Forwarded-For"),
    				pulumi.String("X-Real-IP"),
    			},
    			DefaultBlockingResponseCode: pulumi.Int(429),
    			AttackSignalThresholds:      &fastly.NgwafWorkspaceAttackSignalThresholdsArgs{},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = fastly.NewNgwafWorkspaceSignal(ctx, "example", &fastly.NgwafWorkspaceSignalArgs{
    			WorkspaceId: example.ID(),
    			Description: pulumi.String("example"),
    			Name:        pulumi.String("Test Name"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Fastly = Pulumi.Fastly;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Fastly.NgwafWorkspace("example", new()
        {
            Name = "example",
            Description = "Test NGWAF Workspace",
            Mode = "block",
            IpAnonymization = "hashed",
            ClientIpHeaders = new[]
            {
                "X-Forwarded-For",
                "X-Real-IP",
            },
            DefaultBlockingResponseCode = 429,
            AttackSignalThresholds = null,
        });
    
        var exampleNgwafWorkspaceSignal = new Fastly.NgwafWorkspaceSignal("example", new()
        {
            WorkspaceId = example.Id,
            Description = "example",
            Name = "Test Name",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.fastly.NgwafWorkspace;
    import com.pulumi.fastly.NgwafWorkspaceArgs;
    import com.pulumi.fastly.inputs.NgwafWorkspaceAttackSignalThresholdsArgs;
    import com.pulumi.fastly.NgwafWorkspaceSignal;
    import com.pulumi.fastly.NgwafWorkspaceSignalArgs;
    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 NgwafWorkspace("example", NgwafWorkspaceArgs.builder()
                .name("example")
                .description("Test NGWAF Workspace")
                .mode("block")
                .ipAnonymization("hashed")
                .clientIpHeaders(            
                    "X-Forwarded-For",
                    "X-Real-IP")
                .defaultBlockingResponseCode(429)
                .attackSignalThresholds(NgwafWorkspaceAttackSignalThresholdsArgs.builder()
                    .build())
                .build());
    
            var exampleNgwafWorkspaceSignal = new NgwafWorkspaceSignal("exampleNgwafWorkspaceSignal", NgwafWorkspaceSignalArgs.builder()
                .workspaceId(example.id())
                .description("example")
                .name("Test Name")
                .build());
    
        }
    }
    
    resources:
      example:
        type: fastly:NgwafWorkspace
        properties:
          name: example
          description: Test NGWAF Workspace
          mode: block
          ipAnonymization: hashed
          clientIpHeaders:
            - X-Forwarded-For
            - X-Real-IP
          defaultBlockingResponseCode: 429
          attackSignalThresholds: {}
      exampleNgwafWorkspaceSignal:
        type: fastly:NgwafWorkspaceSignal
        name: example
        properties:
          workspaceId: ${example.id}
          description: example
          name: Test Name
    

    Create NgwafWorkspaceSignal Resource

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

    Constructor syntax

    new NgwafWorkspaceSignal(name: string, args: NgwafWorkspaceSignalArgs, opts?: CustomResourceOptions);
    @overload
    def NgwafWorkspaceSignal(resource_name: str,
                             args: NgwafWorkspaceSignalArgs,
                             opts: Optional[ResourceOptions] = None)
    
    @overload
    def NgwafWorkspaceSignal(resource_name: str,
                             opts: Optional[ResourceOptions] = None,
                             workspace_id: Optional[str] = None,
                             description: Optional[str] = None,
                             name: Optional[str] = None)
    func NewNgwafWorkspaceSignal(ctx *Context, name string, args NgwafWorkspaceSignalArgs, opts ...ResourceOption) (*NgwafWorkspaceSignal, error)
    public NgwafWorkspaceSignal(string name, NgwafWorkspaceSignalArgs args, CustomResourceOptions? opts = null)
    public NgwafWorkspaceSignal(String name, NgwafWorkspaceSignalArgs args)
    public NgwafWorkspaceSignal(String name, NgwafWorkspaceSignalArgs args, CustomResourceOptions options)
    
    type: fastly:NgwafWorkspaceSignal
    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 NgwafWorkspaceSignalArgs
    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 NgwafWorkspaceSignalArgs
    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 NgwafWorkspaceSignalArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args NgwafWorkspaceSignalArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args NgwafWorkspaceSignalArgs
    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 ngwafWorkspaceSignalResource = new Fastly.NgwafWorkspaceSignal("ngwafWorkspaceSignalResource", new()
    {
        WorkspaceId = "string",
        Description = "string",
        Name = "string",
    });
    
    example, err := fastly.NewNgwafWorkspaceSignal(ctx, "ngwafWorkspaceSignalResource", &fastly.NgwafWorkspaceSignalArgs{
    	WorkspaceId: pulumi.String("string"),
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    })
    
    var ngwafWorkspaceSignalResource = new NgwafWorkspaceSignal("ngwafWorkspaceSignalResource", NgwafWorkspaceSignalArgs.builder()
        .workspaceId("string")
        .description("string")
        .name("string")
        .build());
    
    ngwaf_workspace_signal_resource = fastly.NgwafWorkspaceSignal("ngwafWorkspaceSignalResource",
        workspace_id="string",
        description="string",
        name="string")
    
    const ngwafWorkspaceSignalResource = new fastly.NgwafWorkspaceSignal("ngwafWorkspaceSignalResource", {
        workspaceId: "string",
        description: "string",
        name: "string",
    });
    
    type: fastly:NgwafWorkspaceSignal
    properties:
        description: string
        name: string
        workspaceId: string
    

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

    WorkspaceId string
    The ID of the workspace.
    Description string
    The description of the signal.
    Name string
    The name of the signal. Special characters and periods are not accepted.
    WorkspaceId string
    The ID of the workspace.
    Description string
    The description of the signal.
    Name string
    The name of the signal. Special characters and periods are not accepted.
    workspaceId String
    The ID of the workspace.
    description String
    The description of the signal.
    name String
    The name of the signal. Special characters and periods are not accepted.
    workspaceId string
    The ID of the workspace.
    description string
    The description of the signal.
    name string
    The name of the signal. Special characters and periods are not accepted.
    workspace_id str
    The ID of the workspace.
    description str
    The description of the signal.
    name str
    The name of the signal. Special characters and periods are not accepted.
    workspaceId String
    The ID of the workspace.
    description String
    The description of the signal.
    name String
    The name of the signal. Special characters and periods are not accepted.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    ReferenceId string
    The generated reference ID of the signal.
    Id string
    The provider-assigned unique ID for this managed resource.
    ReferenceId string
    The generated reference ID of the signal.
    id String
    The provider-assigned unique ID for this managed resource.
    referenceId String
    The generated reference ID of the signal.
    id string
    The provider-assigned unique ID for this managed resource.
    referenceId string
    The generated reference ID of the signal.
    id str
    The provider-assigned unique ID for this managed resource.
    reference_id str
    The generated reference ID of the signal.
    id String
    The provider-assigned unique ID for this managed resource.
    referenceId String
    The generated reference ID of the signal.

    Look up Existing NgwafWorkspaceSignal Resource

    Get an existing NgwafWorkspaceSignal 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?: NgwafWorkspaceSignalState, opts?: CustomResourceOptions): NgwafWorkspaceSignal
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            name: Optional[str] = None,
            reference_id: Optional[str] = None,
            workspace_id: Optional[str] = None) -> NgwafWorkspaceSignal
    func GetNgwafWorkspaceSignal(ctx *Context, name string, id IDInput, state *NgwafWorkspaceSignalState, opts ...ResourceOption) (*NgwafWorkspaceSignal, error)
    public static NgwafWorkspaceSignal Get(string name, Input<string> id, NgwafWorkspaceSignalState? state, CustomResourceOptions? opts = null)
    public static NgwafWorkspaceSignal get(String name, Output<String> id, NgwafWorkspaceSignalState state, CustomResourceOptions options)
    resources:  _:    type: fastly:NgwafWorkspaceSignal    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:
    Description string
    The description of the signal.
    Name string
    The name of the signal. Special characters and periods are not accepted.
    ReferenceId string
    The generated reference ID of the signal.
    WorkspaceId string
    The ID of the workspace.
    Description string
    The description of the signal.
    Name string
    The name of the signal. Special characters and periods are not accepted.
    ReferenceId string
    The generated reference ID of the signal.
    WorkspaceId string
    The ID of the workspace.
    description String
    The description of the signal.
    name String
    The name of the signal. Special characters and periods are not accepted.
    referenceId String
    The generated reference ID of the signal.
    workspaceId String
    The ID of the workspace.
    description string
    The description of the signal.
    name string
    The name of the signal. Special characters and periods are not accepted.
    referenceId string
    The generated reference ID of the signal.
    workspaceId string
    The ID of the workspace.
    description str
    The description of the signal.
    name str
    The name of the signal. Special characters and periods are not accepted.
    reference_id str
    The generated reference ID of the signal.
    workspace_id str
    The ID of the workspace.
    description String
    The description of the signal.
    name String
    The name of the signal. Special characters and periods are not accepted.
    referenceId String
    The generated reference ID of the signal.
    workspaceId String
    The ID of the workspace.

    Import

    Fastly Next-Gen WAF workspace signals can be imported using the format <workspaceID>/<signalID>, e.g.:

    $ pulumi import fastly:index/ngwafWorkspaceSignal:NgwafWorkspaceSignal demo <workspaceID>/<signalID>
    

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

    Package Details

    Repository
    Fastly pulumi/pulumi-fastly
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the fastly Terraform Provider.
    fastly logo
    Fastly v11.0.0 published on Thursday, Sep 4, 2025 by Pulumi