Show / Hide Table of Contents

Class Rule

With Auth0, you can create custom Javascript snippets that run in a secure, isolated sandbox as part of your authentication pipeline, which are otherwise known as rules. This resource allows you to create and manage rules. You can create global variable for use with rules by using the auth0..RuleConfig resource.

Example Usage

using Pulumi;
using Auth0 = Pulumi.Auth0;

class MyStack : Stack
{
public MyStack()
{
    var myRule = new Auth0.Rule("myRule", new Auth0.RuleArgs
    {
        Enabled = true,
        Script = @"function (user, context, callback) {
callback(null, user, context);
}

",
    });
    var myRuleConfig = new Auth0.RuleConfig("myRuleConfig", new Auth0.RuleConfigArgs
    {
        Key = "foo",
        Value = "bar",
    });
}

}
Inheritance
System.Object
Pulumi.Resource
Pulumi.CustomResource
Rule
Inherited Members
Pulumi.CustomResource.Id
Pulumi.Resource.GetResourceType()
Pulumi.Resource.GetResourceName()
Pulumi.Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Auth0
Assembly: Pulumi.Auth0.dll
Syntax
public class Rule : CustomResource

Constructors

View Source

Rule(String, RuleArgs, CustomResourceOptions)

Create a Rule resource with the given unique name, arguments, and options.

Declaration
public Rule(string name, RuleArgs args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

RuleArgs args

The arguments used to populate this resource's properties

Pulumi.CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

Enabled

Boolean. Indicates whether the rule is enabled.

Declaration
public Output<bool?> Enabled { get; }
Property Value
Type Description
Pulumi.Output<System.Nullable<System.Boolean>>
View Source

Name

String. Name of the rule. May only contain alphanumeric characters, spaces, and hyphens. May neither start nor end with hyphens or spaces.

Declaration
public Output<string> Name { get; }
Property Value
Type Description
Pulumi.Output<System.String>
View Source

Order

Integer. Order in which the rule executes relative to other rules. Lower-valued rules execute first.

Declaration
public Output<int> Order { get; }
Property Value
Type Description
Pulumi.Output<System.Int32>
View Source

Script

String. Code to be executed when the rule runs.

Declaration
public Output<string> Script { get; }
Property Value
Type Description
Pulumi.Output<System.String>

Methods

View Source

Get(String, Input<String>, RuleState, CustomResourceOptions)

Get an existing Rule resource's state with the given name, ID, and optional extra properties used to qualify the lookup.

Declaration
public static Rule Get(string name, Input<string> id, RuleState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Pulumi.Input<System.String> id

The unique provider ID of the resource to lookup.

RuleState state

Any extra arguments used during the lookup.

Pulumi.CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
Rule
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.