1. Packages
  2. New Relic
  3. API Docs
  4. ObfuscationExpression
New Relic v5.33.0 published on Thursday, Sep 26, 2024 by Pulumi

newrelic.ObfuscationExpression

Explore with Pulumi AI

newrelic logo
New Relic v5.33.0 published on Thursday, Sep 26, 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",
        name: "OExp",
        description: "The description",
        regex: "(regex.*)",
    });
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    foo = newrelic.ObfuscationExpression("foo",
        account_id="12345",
        name="OExp",
        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.String("12345"),
    			Name:        pulumi.String("OExp"),
    			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",
            Name = "OExp",
            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)
                .name("OExp")
                .description("The description")
                .regex("(regex.*)")
                .build());
    
        }
    }
    
    resources:
      foo:
        type: newrelic:ObfuscationExpression
        properties:
          accountId: 12345
          name: OExp
          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[str] = 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.

    Constructor example

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

    var obfuscationExpressionResource = new NewRelic.ObfuscationExpression("obfuscationExpressionResource", new()
    {
        Regex = "string",
        AccountId = "string",
        Description = "string",
        Name = "string",
    });
    
    example, err := newrelic.NewObfuscationExpression(ctx, "obfuscationExpressionResource", &newrelic.ObfuscationExpressionArgs{
    	Regex:       pulumi.String("string"),
    	AccountId:   pulumi.String("string"),
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    })
    
    var obfuscationExpressionResource = new ObfuscationExpression("obfuscationExpressionResource", ObfuscationExpressionArgs.builder()
        .regex("string")
        .accountId("string")
        .description("string")
        .name("string")
        .build());
    
    obfuscation_expression_resource = newrelic.ObfuscationExpression("obfuscationExpressionResource",
        regex="string",
        account_id="string",
        description="string",
        name="string")
    
    const obfuscationExpressionResource = new newrelic.ObfuscationExpression("obfuscationExpressionResource", {
        regex: "string",
        accountId: "string",
        description: "string",
        name: "string",
    });
    
    type: newrelic:ObfuscationExpression
    properties:
        accountId: string
        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 string
    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 string
    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 String
    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 string
    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 str
    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 String
    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[str] = 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 string
    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 string
    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 String
    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 string
    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 str
    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 String
    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.33.0 published on Thursday, Sep 26, 2024 by Pulumi