1. Packages
  2. New Relic
  3. API Docs
  4. ObfuscationExpression
New Relic v5.22.1 published on Friday, Mar 29, 2024 by Pulumi

newrelic.ObfuscationExpression

Explore with Pulumi AI

newrelic logo
New Relic v5.22.1 published on Friday, Mar 29, 2024 by Pulumi

    Use this resource to create, update and delete New Relic Obfuscation Expressions.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    const foo = new newrelic.ObfuscationExpression("foo", {
        accountId: 12345,
        description: "The description",
        regex: "(regex.*)",
    });
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    foo = newrelic.ObfuscationExpression("foo",
        account_id=12345,
        description="The description",
        regex="(regex.*)")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-newrelic/sdk/v5/go/newrelic"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := newrelic.NewObfuscationExpression(ctx, "foo", &newrelic.ObfuscationExpressionArgs{
    			AccountId:   pulumi.Int(12345),
    			Description: pulumi.String("The description"),
    			Regex:       pulumi.String("(regex.*)"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        var foo = new NewRelic.ObfuscationExpression("foo", new()
        {
            AccountId = 12345,
            Description = "The description",
            Regex = "(regex.*)",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.ObfuscationExpression;
    import com.pulumi.newrelic.ObfuscationExpressionArgs;
    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 ObfuscationExpression("foo", ObfuscationExpressionArgs.builder()        
                .accountId(12345)
                .description("The description")
                .regex("(regex.*)")
                .build());
    
        }
    }
    
    resources:
      foo:
        type: newrelic:ObfuscationExpression
        properties:
          accountId: 12345
          description: The description
          regex: (regex.*)
    

    Create ObfuscationExpression Resource

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

    Constructor syntax

    new ObfuscationExpression(name: string, args: ObfuscationExpressionArgs, opts?: CustomResourceOptions);
    @overload
    def ObfuscationExpression(resource_name: str,
                              args: ObfuscationExpressionArgs,
                              opts: Optional[ResourceOptions] = None)
    
    @overload
    def ObfuscationExpression(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              regex: Optional[str] = None,
                              account_id: Optional[int] = None,
                              description: Optional[str] = None,
                              name: Optional[str] = None)
    func NewObfuscationExpression(ctx *Context, name string, args ObfuscationExpressionArgs, opts ...ResourceOption) (*ObfuscationExpression, error)
    public ObfuscationExpression(string name, ObfuscationExpressionArgs args, CustomResourceOptions? opts = null)
    public ObfuscationExpression(String name, ObfuscationExpressionArgs args)
    public ObfuscationExpression(String name, ObfuscationExpressionArgs args, CustomResourceOptions options)
    
    type: newrelic:ObfuscationExpression
    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 ObfuscationExpressionArgs
    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 ObfuscationExpressionArgs
    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 ObfuscationExpressionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ObfuscationExpressionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ObfuscationExpressionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

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

    var obfuscationExpressionResource = new NewRelic.ObfuscationExpression("obfuscationExpressionResource", new()
    {
        Regex = "string",
        AccountId = 0,
        Description = "string",
        Name = "string",
    });
    
    example, err := newrelic.NewObfuscationExpression(ctx, "obfuscationExpressionResource", &newrelic.ObfuscationExpressionArgs{
    	Regex:       pulumi.String("string"),
    	AccountId:   pulumi.Int(0),
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    })
    
    var obfuscationExpressionResource = new ObfuscationExpression("obfuscationExpressionResource", ObfuscationExpressionArgs.builder()        
        .regex("string")
        .accountId(0)
        .description("string")
        .name("string")
        .build());
    
    obfuscation_expression_resource = newrelic.ObfuscationExpression("obfuscationExpressionResource",
        regex="string",
        account_id=0,
        description="string",
        name="string")
    
    const obfuscationExpressionResource = new newrelic.ObfuscationExpression("obfuscationExpressionResource", {
        regex: "string",
        accountId: 0,
        description: "string",
        name: "string",
    });
    
    type: newrelic:ObfuscationExpression
    properties:
        accountId: 0
        description: string
        name: string
        regex: string
    

    ObfuscationExpression Resource Properties

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

    Inputs

    The ObfuscationExpression resource accepts the following input properties:

    Regex string
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    AccountId int
    The account id associated with the obfuscation expression.
    Description string
    Description of expression.
    Name string
    Name of expression.
    Regex string
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    AccountId int
    The account id associated with the obfuscation expression.
    Description string
    Description of expression.
    Name string
    Name of expression.
    regex String
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    accountId Integer
    The account id associated with the obfuscation expression.
    description String
    Description of expression.
    name String
    Name of expression.
    regex string
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    accountId number
    The account id associated with the obfuscation expression.
    description string
    Description of expression.
    name string
    Name of expression.
    regex str
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    account_id int
    The account id associated with the obfuscation expression.
    description str
    Description of expression.
    name str
    Name of expression.
    regex String
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    accountId Number
    The account id associated with the obfuscation expression.
    description String
    Description of expression.
    name String
    Name of expression.

    Outputs

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

    Get an existing ObfuscationExpression 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?: ObfuscationExpressionState, opts?: CustomResourceOptions): ObfuscationExpression
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            account_id: Optional[int] = None,
            description: Optional[str] = None,
            name: Optional[str] = None,
            regex: Optional[str] = None) -> ObfuscationExpression
    func GetObfuscationExpression(ctx *Context, name string, id IDInput, state *ObfuscationExpressionState, opts ...ResourceOption) (*ObfuscationExpression, error)
    public static ObfuscationExpression Get(string name, Input<string> id, ObfuscationExpressionState? state, CustomResourceOptions? opts = null)
    public static ObfuscationExpression get(String name, Output<String> id, ObfuscationExpressionState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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:
    AccountId int
    The account id associated with the obfuscation expression.
    Description string
    Description of expression.
    Name string
    Name of expression.
    Regex string
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    AccountId int
    The account id associated with the obfuscation expression.
    Description string
    Description of expression.
    Name string
    Name of expression.
    Regex string
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    accountId Integer
    The account id associated with the obfuscation expression.
    description String
    Description of expression.
    name String
    Name of expression.
    regex String
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    accountId number
    The account id associated with the obfuscation expression.
    description string
    Description of expression.
    name string
    Name of expression.
    regex string
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    account_id int
    The account id associated with the obfuscation expression.
    description str
    Description of expression.
    name str
    Name of expression.
    regex str
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).
    accountId Number
    The account id associated with the obfuscation expression.
    description String
    Description of expression.
    name String
    Name of expression.
    regex String
    Regex of expression. Must be wrapped in parentheses, e.g. (regex.*).

    Import

    New Relic obfuscation expression can be imported using the expression ID, e.g.

    bash

    $ pulumi import newrelic:index/obfuscationExpression:ObfuscationExpression foo 34567
    

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

    Package Details

    Repository
    New Relic pulumi/pulumi-newrelic
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the newrelic Terraform Provider.
    newrelic logo
    New Relic v5.22.1 published on Friday, Mar 29, 2024 by Pulumi