1. Packages
  2. New Relic
  3. API Docs
  4. Workflow
New Relic v5.12.1 published on Thursday, Jun 8, 2023 by Pulumi

newrelic.Workflow

Explore with Pulumi AI

newrelic logo
New Relic v5.12.1 published on Thursday, Jun 8, 2023 by Pulumi

    Use this resource to create and manage New Relic workflows.

    Policy-Based Workflow Example

    This scenario describes one of most common ways of using workflows by defining a set of policies the workflow handles

    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    // Create a policy to track
    const my_policy = new newrelic.AlertPolicy("my-policy", {});
    // Create a reusable notification destination
    const webhook_destination = new newrelic.NotificationDestination("webhook-destination", {
        type: "WEBHOOK",
        properties: [{
            key: "url",
            value: "https://example.com",
        }],
        authBasic: {
            user: "username",
            password: "password",
        },
    });
    // Create a notification channel to use in the workflow
    const webhook_channel = new newrelic.NotificationChannel("webhook-channel", {
        type: "WEBHOOK",
        destinationId: webhook_destination.id,
        product: "IINT",
        properties: [{
            key: "payload",
            value: "{}",
            label: "Payload Template",
        }],
    });
    // A workflow that matches issues that include incidents triggered by the policy
    const workflow_example = new newrelic.Workflow("workflow-example", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "Filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "labels.policyIds",
                operator: "EXACTLY_MATCHES",
                values: [my_policy.id],
            }],
        },
        destinations: [{
            channelId: webhook_channel.id,
        }],
    });
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    # Create a policy to track
    my_policy = newrelic.AlertPolicy("my-policy")
    # Create a reusable notification destination
    webhook_destination = newrelic.NotificationDestination("webhook-destination",
        type="WEBHOOK",
        properties=[newrelic.NotificationDestinationPropertyArgs(
            key="url",
            value="https://example.com",
        )],
        auth_basic=newrelic.NotificationDestinationAuthBasicArgs(
            user="username",
            password="password",
        ))
    # Create a notification channel to use in the workflow
    webhook_channel = newrelic.NotificationChannel("webhook-channel",
        type="WEBHOOK",
        destination_id=webhook_destination.id,
        product="IINT",
        properties=[newrelic.NotificationChannelPropertyArgs(
            key="payload",
            value="{}",
            label="Payload Template",
        )])
    # A workflow that matches issues that include incidents triggered by the policy
    workflow_example = newrelic.Workflow("workflow-example",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="Filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="labels.policyIds",
                operator="EXACTLY_MATCHES",
                values=[my_policy.id],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=webhook_channel.id,
        )])
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        // Create a policy to track
        var my_policy = new NewRelic.AlertPolicy("my-policy");
    
        // Create a reusable notification destination
        var webhook_destination = new NewRelic.NotificationDestination("webhook-destination", new()
        {
            Type = "WEBHOOK",
            Properties = new[]
            {
                new NewRelic.Inputs.NotificationDestinationPropertyArgs
                {
                    Key = "url",
                    Value = "https://example.com",
                },
            },
            AuthBasic = new NewRelic.Inputs.NotificationDestinationAuthBasicArgs
            {
                User = "username",
                Password = "password",
            },
        });
    
        // Create a notification channel to use in the workflow
        var webhook_channel = new NewRelic.NotificationChannel("webhook-channel", new()
        {
            Type = "WEBHOOK",
            DestinationId = webhook_destination.Id,
            Product = "IINT",
            Properties = new[]
            {
                new NewRelic.Inputs.NotificationChannelPropertyArgs
                {
                    Key = "payload",
                    Value = "{}",
                    Label = "Payload Template",
                },
            },
        });
    
        // A workflow that matches issues that include incidents triggered by the policy
        var workflow_example = new NewRelic.Workflow("workflow-example", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "Filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "labels.policyIds",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            my_policy.Id,
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = webhook_channel.Id,
                },
            },
        });
    
    });
    
    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.NewAlertPolicy(ctx, "my-policy", nil)
    		if err != nil {
    			return err
    		}
    		_, err = newrelic.NewNotificationDestination(ctx, "webhook-destination", &newrelic.NotificationDestinationArgs{
    			Type: pulumi.String("WEBHOOK"),
    			Properties: newrelic.NotificationDestinationPropertyArray{
    				&newrelic.NotificationDestinationPropertyArgs{
    					Key:   pulumi.String("url"),
    					Value: pulumi.String("https://example.com"),
    				},
    			},
    			AuthBasic: &newrelic.NotificationDestinationAuthBasicArgs{
    				User:     pulumi.String("username"),
    				Password: pulumi.String("password"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = newrelic.NewNotificationChannel(ctx, "webhook-channel", &newrelic.NotificationChannelArgs{
    			Type:          pulumi.String("WEBHOOK"),
    			DestinationId: webhook_destination.ID(),
    			Product:       pulumi.String("IINT"),
    			Properties: newrelic.NotificationChannelPropertyArray{
    				&newrelic.NotificationChannelPropertyArgs{
    					Key:   pulumi.String("payload"),
    					Value: pulumi.String("{}"),
    					Label: pulumi.String("Payload Template"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = newrelic.NewWorkflow(ctx, "workflow-example", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("Filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("labels.policyIds"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							my_policy.ID(),
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: webhook_channel.ID(),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.AlertPolicy;
    import com.pulumi.newrelic.NotificationDestination;
    import com.pulumi.newrelic.NotificationDestinationArgs;
    import com.pulumi.newrelic.inputs.NotificationDestinationPropertyArgs;
    import com.pulumi.newrelic.inputs.NotificationDestinationAuthBasicArgs;
    import com.pulumi.newrelic.NotificationChannel;
    import com.pulumi.newrelic.NotificationChannelArgs;
    import com.pulumi.newrelic.inputs.NotificationChannelPropertyArgs;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 my_policy = new AlertPolicy("my-policy");
    
            var webhook_destination = new NotificationDestination("webhook-destination", NotificationDestinationArgs.builder()        
                .type("WEBHOOK")
                .properties(NotificationDestinationPropertyArgs.builder()
                    .key("url")
                    .value("https://example.com")
                    .build())
                .authBasic(NotificationDestinationAuthBasicArgs.builder()
                    .user("username")
                    .password("password")
                    .build())
                .build());
    
            var webhook_channel = new NotificationChannel("webhook-channel", NotificationChannelArgs.builder()        
                .type("WEBHOOK")
                .destinationId(webhook_destination.id())
                .product("IINT")
                .properties(NotificationChannelPropertyArgs.builder()
                    .key("payload")
                    .value("{}")
                    .label("Payload Template")
                    .build())
                .build());
    
            var workflow_example = new Workflow("workflow-example", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("Filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("labels.policyIds")
                        .operator("EXACTLY_MATCHES")
                        .values(my_policy.id())
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(webhook_channel.id())
                    .build())
                .build());
    
        }
    }
    
    resources:
      # Create a policy to track
      my-policy:
        type: newrelic:AlertPolicy
      # Create a reusable notification destination
      webhook-destination:
        type: newrelic:NotificationDestination
        properties:
          type: WEBHOOK
          properties:
            - key: url
              value: https://example.com
          authBasic:
            user: username
            password: password
      # Create a notification channel to use in the workflow
      webhook-channel:
        type: newrelic:NotificationChannel
        properties:
          type: WEBHOOK
          destinationId: ${["webhook-destination"].id}
          product: IINT # Please note the product used!
          properties:
            - key: payload
              value: '{}'
              label: Payload Template
      # A workflow that matches issues that include incidents triggered by the policy
      workflow-example:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: Filter-name
            type: FILTER
            predicates:
              - attribute: labels.policyIds
                operator: EXACTLY_MATCHES
                values:
                  - ${["my-policy"].id}
          destinations:
            - channelId: ${["webhook-channel"].id}
    

    An example of a workflow with enrichments

    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    const workflow_example = new newrelic.Workflow("workflow-example", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "Filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "accumulations.tag.team",
                operator: "EXACTLY_MATCHES",
                values: ["my_team"],
            }],
        },
        enrichments: {
            nrqls: [{
                name: "Log Count",
                configurations: [{
                    query: "SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago",
                }],
            }],
        },
        destinations: [{
            channelId: newrelic_notification_channel["webhook-channel"].id,
        }],
    });
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    workflow_example = newrelic.Workflow("workflow-example",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="Filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="accumulations.tag.team",
                operator="EXACTLY_MATCHES",
                values=["my_team"],
            )],
        ),
        enrichments=newrelic.WorkflowEnrichmentsArgs(
            nrqls=[newrelic.WorkflowEnrichmentsNrqlArgs(
                name="Log Count",
                configurations=[newrelic.WorkflowEnrichmentsNrqlConfigurationArgs(
                    query="SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago",
                )],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),
        )])
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        var workflow_example = new NewRelic.Workflow("workflow-example", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "Filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "accumulations.tag.team",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            "my_team",
                        },
                    },
                },
            },
            Enrichments = new NewRelic.Inputs.WorkflowEnrichmentsArgs
            {
                Nrqls = new[]
                {
                    new NewRelic.Inputs.WorkflowEnrichmentsNrqlArgs
                    {
                        Name = "Log Count",
                        Configurations = new[]
                        {
                            new NewRelic.Inputs.WorkflowEnrichmentsNrqlConfigurationArgs
                            {
                                Query = "SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago",
                            },
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = newrelic_notification_channel.Webhook_channel.Id,
                },
            },
        });
    
    });
    
    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.NewWorkflow(ctx, "workflow-example", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("Filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("accumulations.tag.team"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							pulumi.String("my_team"),
    						},
    					},
    				},
    			},
    			Enrichments: &newrelic.WorkflowEnrichmentsArgs{
    				Nrqls: newrelic.WorkflowEnrichmentsNrqlArray{
    					&newrelic.WorkflowEnrichmentsNrqlArgs{
    						Name: pulumi.String("Log Count"),
    						Configurations: newrelic.WorkflowEnrichmentsNrqlConfigurationArray{
    							&newrelic.WorkflowEnrichmentsNrqlConfigurationArgs{
    								Query: pulumi.String("SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago"),
    							},
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: pulumi.Any(newrelic_notification_channel.WebhookChannel.Id),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowEnrichmentsArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 workflow_example = new Workflow("workflow-example", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("Filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("accumulations.tag.team")
                        .operator("EXACTLY_MATCHES")
                        .values("my_team")
                        .build())
                    .build())
                .enrichments(WorkflowEnrichmentsArgs.builder()
                    .nrqls(WorkflowEnrichmentsNrqlArgs.builder()
                        .name("Log Count")
                        .configurations(WorkflowEnrichmentsNrqlConfigurationArgs.builder()
                            .query("SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago")
                            .build())
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(newrelic_notification_channel.webhook-channel().id())
                    .build())
                .build());
    
        }
    }
    
    resources:
      workflow-example:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: Filter-name
            type: FILTER
            predicates:
              - attribute: accumulations.tag.team
                operator: EXACTLY_MATCHES
                values:
                  - my_team
          enrichments:
            nrqls:
              - name: Log Count
                configurations:
                  - query: SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago
          destinations:
            - channelId: ${newrelic_notification_channel"webhook-channel"[%!s(MISSING)].id}
    

    An example of a workflow with notification triggers

    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    const workflow_example = new newrelic.Workflow("workflow-example", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "Filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "accumulations.tag.team",
                operator: "EXACTLY_MATCHES",
                values: ["my_team"],
            }],
        },
        destinations: [{
            channelId: newrelic_notification_channel["webhook-channel"].id,
            notificationTriggers: ["ACTIVATED"],
        }],
    });
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    workflow_example = newrelic.Workflow("workflow-example",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="Filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="accumulations.tag.team",
                operator="EXACTLY_MATCHES",
                values=["my_team"],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),
            notification_triggers=["ACTIVATED"],
        )])
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        var workflow_example = new NewRelic.Workflow("workflow-example", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "Filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "accumulations.tag.team",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            "my_team",
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = newrelic_notification_channel.Webhook_channel.Id,
                    NotificationTriggers = new[]
                    {
                        "ACTIVATED",
                    },
                },
            },
        });
    
    });
    
    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.NewWorkflow(ctx, "workflow-example", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("Filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("accumulations.tag.team"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							pulumi.String("my_team"),
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: pulumi.Any(newrelic_notification_channel.WebhookChannel.Id),
    					NotificationTriggers: pulumi.StringArray{
    						pulumi.String("ACTIVATED"),
    					},
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 workflow_example = new Workflow("workflow-example", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("Filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("accumulations.tag.team")
                        .operator("EXACTLY_MATCHES")
                        .values("my_team")
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(newrelic_notification_channel.webhook-channel().id())
                    .notificationTriggers("ACTIVATED")
                    .build())
                .build());
    
        }
    }
    
    resources:
      workflow-example:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: Filter-name
            type: FILTER
            predicates:
              - attribute: accumulations.tag.team
                operator: EXACTLY_MATCHES
                values:
                  - my_team
          destinations:
            - channelId: ${newrelic_notification_channel"webhook-channel"[%!s(MISSING)].id}
              notificationTriggers:
                - ACTIVATED
    

    Additional Information

    More details about the workflows can be found here.

    v3.3 changes

    In version v3.3 we renamed the following arguments:

    • workflow_enabled changed to enabled.
    • destination_configuration changed to destination.
    • predicates changed to predicate.
    • Enrichment’s configurations changed to configuration.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        var foo = new NewRelic.Workflow("foo", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "accumulations.tag.team",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            "growth",
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = newrelic_notification_channel.Some_channel.Id,
                },
            },
        });
    
    });
    
    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.NewWorkflow(ctx, "foo", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("accumulations.tag.team"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							pulumi.String("growth"),
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: pulumi.Any(newrelic_notification_channel.Some_channel.Id),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 Workflow("foo", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("accumulations.tag.team")
                        .operator("EXACTLY_MATCHES")
                        .values("growth")
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(newrelic_notification_channel.some_channel().id())
                    .build())
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    foo = newrelic.Workflow("foo",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="accumulations.tag.team",
                operator="EXACTLY_MATCHES",
                values=["growth"],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),
        )])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    const foo = new newrelic.Workflow("foo", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "accumulations.tag.team",
                operator: "EXACTLY_MATCHES",
                values: ["growth"],
            }],
        },
        destinations: [{
            channelId: newrelic_notification_channel.some_channel.id,
        }],
    });
    
    resources:
      foo:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: filter-name
            type: FILTER
            predicates:
              - attribute: accumulations.tag.team
                operator: EXACTLY_MATCHES
                values:
                  - growth
          destinations:
            - channelId: ${newrelic_notification_channel.some_channel.id}
    

    This scenario describes one of most common ways of using workflows by defining a set of policies the workflow handles

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        // Create a policy to track
        var my_policy = new NewRelic.AlertPolicy("my-policy");
    
        // Create a reusable notification destination
        var webhook_destination = new NewRelic.NotificationDestination("webhook-destination", new()
        {
            Type = "WEBHOOK",
            Properties = new[]
            {
                new NewRelic.Inputs.NotificationDestinationPropertyArgs
                {
                    Key = "url",
                    Value = "https://example.com",
                },
            },
            AuthBasic = new NewRelic.Inputs.NotificationDestinationAuthBasicArgs
            {
                User = "username",
                Password = "password",
            },
        });
    
        // Create a notification channel to use in the workflow
        var webhook_channel = new NewRelic.NotificationChannel("webhook-channel", new()
        {
            Type = "WEBHOOK",
            DestinationId = webhook_destination.Id,
            Product = "IINT",
            Properties = new[]
            {
                new NewRelic.Inputs.NotificationChannelPropertyArgs
                {
                    Key = "payload",
                    Value = "{}",
                    Label = "Payload Template",
                },
            },
        });
    
        // A workflow that matches issues that include incidents triggered by the policy
        var workflow_example = new NewRelic.Workflow("workflow-example", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "Filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "labels.policyIds",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            my_policy.Id,
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = webhook_channel.Id,
                },
            },
        });
    
    });
    
    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.NewAlertPolicy(ctx, "my-policy", nil)
    		if err != nil {
    			return err
    		}
    		_, err = newrelic.NewNotificationDestination(ctx, "webhook-destination", &newrelic.NotificationDestinationArgs{
    			Type: pulumi.String("WEBHOOK"),
    			Properties: newrelic.NotificationDestinationPropertyArray{
    				&newrelic.NotificationDestinationPropertyArgs{
    					Key:   pulumi.String("url"),
    					Value: pulumi.String("https://example.com"),
    				},
    			},
    			AuthBasic: &newrelic.NotificationDestinationAuthBasicArgs{
    				User:     pulumi.String("username"),
    				Password: pulumi.String("password"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = newrelic.NewNotificationChannel(ctx, "webhook-channel", &newrelic.NotificationChannelArgs{
    			Type:          pulumi.String("WEBHOOK"),
    			DestinationId: webhook_destination.ID(),
    			Product:       pulumi.String("IINT"),
    			Properties: newrelic.NotificationChannelPropertyArray{
    				&newrelic.NotificationChannelPropertyArgs{
    					Key:   pulumi.String("payload"),
    					Value: pulumi.String("{}"),
    					Label: pulumi.String("Payload Template"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = newrelic.NewWorkflow(ctx, "workflow-example", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("Filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("labels.policyIds"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							my_policy.ID(),
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: webhook_channel.ID(),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.AlertPolicy;
    import com.pulumi.newrelic.NotificationDestination;
    import com.pulumi.newrelic.NotificationDestinationArgs;
    import com.pulumi.newrelic.inputs.NotificationDestinationPropertyArgs;
    import com.pulumi.newrelic.inputs.NotificationDestinationAuthBasicArgs;
    import com.pulumi.newrelic.NotificationChannel;
    import com.pulumi.newrelic.NotificationChannelArgs;
    import com.pulumi.newrelic.inputs.NotificationChannelPropertyArgs;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 my_policy = new AlertPolicy("my-policy");
    
            var webhook_destination = new NotificationDestination("webhook-destination", NotificationDestinationArgs.builder()        
                .type("WEBHOOK")
                .properties(NotificationDestinationPropertyArgs.builder()
                    .key("url")
                    .value("https://example.com")
                    .build())
                .authBasic(NotificationDestinationAuthBasicArgs.builder()
                    .user("username")
                    .password("password")
                    .build())
                .build());
    
            var webhook_channel = new NotificationChannel("webhook-channel", NotificationChannelArgs.builder()        
                .type("WEBHOOK")
                .destinationId(webhook_destination.id())
                .product("IINT")
                .properties(NotificationChannelPropertyArgs.builder()
                    .key("payload")
                    .value("{}")
                    .label("Payload Template")
                    .build())
                .build());
    
            var workflow_example = new Workflow("workflow-example", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("Filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("labels.policyIds")
                        .operator("EXACTLY_MATCHES")
                        .values(my_policy.id())
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(webhook_channel.id())
                    .build())
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    # Create a policy to track
    my_policy = newrelic.AlertPolicy("my-policy")
    # Create a reusable notification destination
    webhook_destination = newrelic.NotificationDestination("webhook-destination",
        type="WEBHOOK",
        properties=[newrelic.NotificationDestinationPropertyArgs(
            key="url",
            value="https://example.com",
        )],
        auth_basic=newrelic.NotificationDestinationAuthBasicArgs(
            user="username",
            password="password",
        ))
    # Create a notification channel to use in the workflow
    webhook_channel = newrelic.NotificationChannel("webhook-channel",
        type="WEBHOOK",
        destination_id=webhook_destination.id,
        product="IINT",
        properties=[newrelic.NotificationChannelPropertyArgs(
            key="payload",
            value="{}",
            label="Payload Template",
        )])
    # A workflow that matches issues that include incidents triggered by the policy
    workflow_example = newrelic.Workflow("workflow-example",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="Filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="labels.policyIds",
                operator="EXACTLY_MATCHES",
                values=[my_policy.id],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=webhook_channel.id,
        )])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    // Create a policy to track
    const my_policy = new newrelic.AlertPolicy("my-policy", {});
    // Create a reusable notification destination
    const webhook_destination = new newrelic.NotificationDestination("webhook-destination", {
        type: "WEBHOOK",
        properties: [{
            key: "url",
            value: "https://example.com",
        }],
        authBasic: {
            user: "username",
            password: "password",
        },
    });
    // Create a notification channel to use in the workflow
    const webhook_channel = new newrelic.NotificationChannel("webhook-channel", {
        type: "WEBHOOK",
        destinationId: webhook_destination.id,
        product: "IINT",
        properties: [{
            key: "payload",
            value: "{}",
            label: "Payload Template",
        }],
    });
    // A workflow that matches issues that include incidents triggered by the policy
    const workflow_example = new newrelic.Workflow("workflow-example", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "Filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "labels.policyIds",
                operator: "EXACTLY_MATCHES",
                values: [my_policy.id],
            }],
        },
        destinations: [{
            channelId: webhook_channel.id,
        }],
    });
    
    resources:
      # Create a policy to track
      my-policy:
        type: newrelic:AlertPolicy
      # Create a reusable notification destination
      webhook-destination:
        type: newrelic:NotificationDestination
        properties:
          type: WEBHOOK
          properties:
            - key: url
              value: https://example.com
          authBasic:
            user: username
            password: password
      # Create a notification channel to use in the workflow
      webhook-channel:
        type: newrelic:NotificationChannel
        properties:
          type: WEBHOOK
          destinationId: ${["webhook-destination"].id}
          product: IINT # Please note the product used!
          properties:
            - key: payload
              value: '{}'
              label: Payload Template
      # A workflow that matches issues that include incidents triggered by the policy
      workflow-example:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: Filter-name
            type: FILTER
            predicates:
              - attribute: labels.policyIds
                operator: EXACTLY_MATCHES
                values:
                  - ${["my-policy"].id}
          destinations:
            - channelId: ${["webhook-channel"].id}
    

    An example of a workflow with enrichments

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        var workflow_example = new NewRelic.Workflow("workflow-example", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "Filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "accumulations.tag.team",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            "my_team",
                        },
                    },
                },
            },
            Enrichments = new NewRelic.Inputs.WorkflowEnrichmentsArgs
            {
                Nrqls = new[]
                {
                    new NewRelic.Inputs.WorkflowEnrichmentsNrqlArgs
                    {
                        Name = "Log Count",
                        Configurations = new[]
                        {
                            new NewRelic.Inputs.WorkflowEnrichmentsNrqlConfigurationArgs
                            {
                                Query = "SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago",
                            },
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = newrelic_notification_channel.Webhook_channel.Id,
                },
            },
        });
    
    });
    
    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.NewWorkflow(ctx, "workflow-example", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("Filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("accumulations.tag.team"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							pulumi.String("my_team"),
    						},
    					},
    				},
    			},
    			Enrichments: &newrelic.WorkflowEnrichmentsArgs{
    				Nrqls: newrelic.WorkflowEnrichmentsNrqlArray{
    					&newrelic.WorkflowEnrichmentsNrqlArgs{
    						Name: pulumi.String("Log Count"),
    						Configurations: newrelic.WorkflowEnrichmentsNrqlConfigurationArray{
    							&newrelic.WorkflowEnrichmentsNrqlConfigurationArgs{
    								Query: pulumi.String("SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago"),
    							},
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: pulumi.Any(newrelic_notification_channel.WebhookChannel.Id),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowEnrichmentsArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 workflow_example = new Workflow("workflow-example", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("Filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("accumulations.tag.team")
                        .operator("EXACTLY_MATCHES")
                        .values("my_team")
                        .build())
                    .build())
                .enrichments(WorkflowEnrichmentsArgs.builder()
                    .nrqls(WorkflowEnrichmentsNrqlArgs.builder()
                        .name("Log Count")
                        .configurations(WorkflowEnrichmentsNrqlConfigurationArgs.builder()
                            .query("SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago")
                            .build())
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(newrelic_notification_channel.webhook-channel().id())
                    .build())
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    workflow_example = newrelic.Workflow("workflow-example",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="Filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="accumulations.tag.team",
                operator="EXACTLY_MATCHES",
                values=["my_team"],
            )],
        ),
        enrichments=newrelic.WorkflowEnrichmentsArgs(
            nrqls=[newrelic.WorkflowEnrichmentsNrqlArgs(
                name="Log Count",
                configurations=[newrelic.WorkflowEnrichmentsNrqlConfigurationArgs(
                    query="SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago",
                )],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),
        )])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    const workflow_example = new newrelic.Workflow("workflow-example", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "Filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "accumulations.tag.team",
                operator: "EXACTLY_MATCHES",
                values: ["my_team"],
            }],
        },
        enrichments: {
            nrqls: [{
                name: "Log Count",
                configurations: [{
                    query: "SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago",
                }],
            }],
        },
        destinations: [{
            channelId: newrelic_notification_channel["webhook-channel"].id,
        }],
    });
    
    resources:
      workflow-example:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: Filter-name
            type: FILTER
            predicates:
              - attribute: accumulations.tag.team
                operator: EXACTLY_MATCHES
                values:
                  - my_team
          enrichments:
            nrqls:
              - name: Log Count
                configurations:
                  - query: SELECT count(*) FROM Log WHERE message like '%error%' since 10 minutes ago
          destinations:
            - channelId: ${newrelic_notification_channel"webhook-channel"[%!s(MISSING)].id}
    

    An example of a workflow with notification triggers

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using NewRelic = Pulumi.NewRelic;
    
    return await Deployment.RunAsync(() => 
    {
        var workflow_example = new NewRelic.Workflow("workflow-example", new()
        {
            MutingRulesHandling = "NOTIFY_ALL_ISSUES",
            IssuesFilter = new NewRelic.Inputs.WorkflowIssuesFilterArgs
            {
                Name = "Filter-name",
                Type = "FILTER",
                Predicates = new[]
                {
                    new NewRelic.Inputs.WorkflowIssuesFilterPredicateArgs
                    {
                        Attribute = "accumulations.tag.team",
                        Operator = "EXACTLY_MATCHES",
                        Values = new[]
                        {
                            "my_team",
                        },
                    },
                },
            },
            Destinations = new[]
            {
                new NewRelic.Inputs.WorkflowDestinationArgs
                {
                    ChannelId = newrelic_notification_channel.Webhook_channel.Id,
                    NotificationTriggers = new[]
                    {
                        "ACTIVATED",
                    },
                },
            },
        });
    
    });
    
    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.NewWorkflow(ctx, "workflow-example", &newrelic.WorkflowArgs{
    			MutingRulesHandling: pulumi.String("NOTIFY_ALL_ISSUES"),
    			IssuesFilter: &newrelic.WorkflowIssuesFilterArgs{
    				Name: pulumi.String("Filter-name"),
    				Type: pulumi.String("FILTER"),
    				Predicates: newrelic.WorkflowIssuesFilterPredicateArray{
    					&newrelic.WorkflowIssuesFilterPredicateArgs{
    						Attribute: pulumi.String("accumulations.tag.team"),
    						Operator:  pulumi.String("EXACTLY_MATCHES"),
    						Values: pulumi.StringArray{
    							pulumi.String("my_team"),
    						},
    					},
    				},
    			},
    			Destinations: newrelic.WorkflowDestinationArray{
    				&newrelic.WorkflowDestinationArgs{
    					ChannelId: pulumi.Any(newrelic_notification_channel.WebhookChannel.Id),
    					NotificationTriggers: pulumi.StringArray{
    						pulumi.String("ACTIVATED"),
    					},
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.newrelic.Workflow;
    import com.pulumi.newrelic.WorkflowArgs;
    import com.pulumi.newrelic.inputs.WorkflowIssuesFilterArgs;
    import com.pulumi.newrelic.inputs.WorkflowDestinationArgs;
    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 workflow_example = new Workflow("workflow-example", WorkflowArgs.builder()        
                .mutingRulesHandling("NOTIFY_ALL_ISSUES")
                .issuesFilter(WorkflowIssuesFilterArgs.builder()
                    .name("Filter-name")
                    .type("FILTER")
                    .predicates(WorkflowIssuesFilterPredicateArgs.builder()
                        .attribute("accumulations.tag.team")
                        .operator("EXACTLY_MATCHES")
                        .values("my_team")
                        .build())
                    .build())
                .destinations(WorkflowDestinationArgs.builder()
                    .channelId(newrelic_notification_channel.webhook-channel().id())
                    .notificationTriggers("ACTIVATED")
                    .build())
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_newrelic as newrelic
    
    workflow_example = newrelic.Workflow("workflow-example",
        muting_rules_handling="NOTIFY_ALL_ISSUES",
        issues_filter=newrelic.WorkflowIssuesFilterArgs(
            name="Filter-name",
            type="FILTER",
            predicates=[newrelic.WorkflowIssuesFilterPredicateArgs(
                attribute="accumulations.tag.team",
                operator="EXACTLY_MATCHES",
                values=["my_team"],
            )],
        ),
        destinations=[newrelic.WorkflowDestinationArgs(
            channel_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),
            notification_triggers=["ACTIVATED"],
        )])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as newrelic from "@pulumi/newrelic";
    
    const workflow_example = new newrelic.Workflow("workflow-example", {
        mutingRulesHandling: "NOTIFY_ALL_ISSUES",
        issuesFilter: {
            name: "Filter-name",
            type: "FILTER",
            predicates: [{
                attribute: "accumulations.tag.team",
                operator: "EXACTLY_MATCHES",
                values: ["my_team"],
            }],
        },
        destinations: [{
            channelId: newrelic_notification_channel["webhook-channel"].id,
            notificationTriggers: ["ACTIVATED"],
        }],
    });
    
    resources:
      workflow-example:
        type: newrelic:Workflow
        properties:
          mutingRulesHandling: NOTIFY_ALL_ISSUES
          issuesFilter:
            name: Filter-name
            type: FILTER
            predicates:
              - attribute: accumulations.tag.team
                operator: EXACTLY_MATCHES
                values:
                  - my_team
          destinations:
            - channelId: ${newrelic_notification_channel"webhook-channel"[%!s(MISSING)].id}
              notificationTriggers:
                - ACTIVATED
    

    Create Workflow Resource

    new Workflow(name: string, args: WorkflowArgs, opts?: CustomResourceOptions);
    @overload
    def Workflow(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 account_id: Optional[int] = None,
                 destinations: Optional[Sequence[WorkflowDestinationArgs]] = None,
                 destinations_enabled: Optional[bool] = None,
                 enabled: Optional[bool] = None,
                 enrichments: Optional[WorkflowEnrichmentsArgs] = None,
                 enrichments_enabled: Optional[bool] = None,
                 issues_filter: Optional[WorkflowIssuesFilterArgs] = None,
                 muting_rules_handling: Optional[str] = None,
                 name: Optional[str] = None)
    @overload
    def Workflow(resource_name: str,
                 args: WorkflowArgs,
                 opts: Optional[ResourceOptions] = None)
    func NewWorkflow(ctx *Context, name string, args WorkflowArgs, opts ...ResourceOption) (*Workflow, error)
    public Workflow(string name, WorkflowArgs args, CustomResourceOptions? opts = null)
    public Workflow(String name, WorkflowArgs args)
    public Workflow(String name, WorkflowArgs args, CustomResourceOptions options)
    
    type: newrelic:Workflow
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args WorkflowArgs
    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 WorkflowArgs
    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 WorkflowArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

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

    Destinations List<Pulumi.NewRelic.Inputs.WorkflowDestinationArgs>

    Notification configuration. See Nested destination blocks below for details.

    IssuesFilter Pulumi.NewRelic.Inputs.WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    MutingRulesHandling string

    How to handle muted issues. See Muting Rules below for details.

    AccountId int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    DestinationsEnabled bool

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    Enabled bool

    Whether workflow is enabled. Defaults to true.

    Enrichments Pulumi.NewRelic.Inputs.WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    EnrichmentsEnabled bool

    Whether enrichments are enabled. Defaults to true.

    Name string

    The name of the workflow.

    Destinations []WorkflowDestinationArgs

    Notification configuration. See Nested destination blocks below for details.

    IssuesFilter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    MutingRulesHandling string

    How to handle muted issues. See Muting Rules below for details.

    AccountId int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    DestinationsEnabled bool

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    Enabled bool

    Whether workflow is enabled. Defaults to true.

    Enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    EnrichmentsEnabled bool

    Whether enrichments are enabled. Defaults to true.

    Name string

    The name of the workflow.

    destinations List<WorkflowDestinationArgs>

    Notification configuration. See Nested destination blocks below for details.

    issuesFilter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    mutingRulesHandling String

    How to handle muted issues. See Muting Rules below for details.

    accountId Integer

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinationsEnabled Boolean

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled Boolean

    Whether workflow is enabled. Defaults to true.

    enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichmentsEnabled Boolean

    Whether enrichments are enabled. Defaults to true.

    name String

    The name of the workflow.

    destinations WorkflowDestinationArgs[]

    Notification configuration. See Nested destination blocks below for details.

    issuesFilter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    mutingRulesHandling string

    How to handle muted issues. See Muting Rules below for details.

    accountId number

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinationsEnabled boolean

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled boolean

    Whether workflow is enabled. Defaults to true.

    enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichmentsEnabled boolean

    Whether enrichments are enabled. Defaults to true.

    name string

    The name of the workflow.

    destinations Sequence[WorkflowDestinationArgs]

    Notification configuration. See Nested destination blocks below for details.

    issues_filter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    muting_rules_handling str

    How to handle muted issues. See Muting Rules below for details.

    account_id int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinations_enabled bool

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled bool

    Whether workflow is enabled. Defaults to true.

    enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichments_enabled bool

    Whether enrichments are enabled. Defaults to true.

    name str

    The name of the workflow.

    destinations List<Property Map>

    Notification configuration. See Nested destination blocks below for details.

    issuesFilter Property Map

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    mutingRulesHandling String

    How to handle muted issues. See Muting Rules below for details.

    accountId Number

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinationsEnabled Boolean

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled Boolean

    Whether workflow is enabled. Defaults to true.

    enrichments Property Map

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichmentsEnabled Boolean

    Whether enrichments are enabled. Defaults to true.

    name String

    The name of the workflow.

    Outputs

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

    Guid string

    Workflow entity GUID

    Id string

    The provider-assigned unique ID for this managed resource.

    LastRun string

    The last time notification was sent for this workflow.

    WorkflowId string

    The id of the workflow.

    Guid string

    Workflow entity GUID

    Id string

    The provider-assigned unique ID for this managed resource.

    LastRun string

    The last time notification was sent for this workflow.

    WorkflowId string

    The id of the workflow.

    guid String

    Workflow entity GUID

    id String

    The provider-assigned unique ID for this managed resource.

    lastRun String

    The last time notification was sent for this workflow.

    workflowId String

    The id of the workflow.

    guid string

    Workflow entity GUID

    id string

    The provider-assigned unique ID for this managed resource.

    lastRun string

    The last time notification was sent for this workflow.

    workflowId string

    The id of the workflow.

    guid str

    Workflow entity GUID

    id str

    The provider-assigned unique ID for this managed resource.

    last_run str

    The last time notification was sent for this workflow.

    workflow_id str

    The id of the workflow.

    guid String

    Workflow entity GUID

    id String

    The provider-assigned unique ID for this managed resource.

    lastRun String

    The last time notification was sent for this workflow.

    workflowId String

    The id of the workflow.

    Look up Existing Workflow Resource

    Get an existing Workflow 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?: WorkflowState, opts?: CustomResourceOptions): Workflow
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            account_id: Optional[int] = None,
            destinations: Optional[Sequence[WorkflowDestinationArgs]] = None,
            destinations_enabled: Optional[bool] = None,
            enabled: Optional[bool] = None,
            enrichments: Optional[WorkflowEnrichmentsArgs] = None,
            enrichments_enabled: Optional[bool] = None,
            guid: Optional[str] = None,
            issues_filter: Optional[WorkflowIssuesFilterArgs] = None,
            last_run: Optional[str] = None,
            muting_rules_handling: Optional[str] = None,
            name: Optional[str] = None,
            workflow_id: Optional[str] = None) -> Workflow
    func GetWorkflow(ctx *Context, name string, id IDInput, state *WorkflowState, opts ...ResourceOption) (*Workflow, error)
    public static Workflow Get(string name, Input<string> id, WorkflowState? state, CustomResourceOptions? opts = null)
    public static Workflow get(String name, Output<String> id, WorkflowState 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

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    Destinations List<Pulumi.NewRelic.Inputs.WorkflowDestinationArgs>

    Notification configuration. See Nested destination blocks below for details.

    DestinationsEnabled bool

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    Enabled bool

    Whether workflow is enabled. Defaults to true.

    Enrichments Pulumi.NewRelic.Inputs.WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    EnrichmentsEnabled bool

    Whether enrichments are enabled. Defaults to true.

    Guid string

    Workflow entity GUID

    IssuesFilter Pulumi.NewRelic.Inputs.WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    LastRun string

    The last time notification was sent for this workflow.

    MutingRulesHandling string

    How to handle muted issues. See Muting Rules below for details.

    Name string

    The name of the workflow.

    WorkflowId string

    The id of the workflow.

    AccountId int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    Destinations []WorkflowDestinationArgs

    Notification configuration. See Nested destination blocks below for details.

    DestinationsEnabled bool

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    Enabled bool

    Whether workflow is enabled. Defaults to true.

    Enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    EnrichmentsEnabled bool

    Whether enrichments are enabled. Defaults to true.

    Guid string

    Workflow entity GUID

    IssuesFilter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    LastRun string

    The last time notification was sent for this workflow.

    MutingRulesHandling string

    How to handle muted issues. See Muting Rules below for details.

    Name string

    The name of the workflow.

    WorkflowId string

    The id of the workflow.

    accountId Integer

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinations List<WorkflowDestinationArgs>

    Notification configuration. See Nested destination blocks below for details.

    destinationsEnabled Boolean

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled Boolean

    Whether workflow is enabled. Defaults to true.

    enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichmentsEnabled Boolean

    Whether enrichments are enabled. Defaults to true.

    guid String

    Workflow entity GUID

    issuesFilter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    lastRun String

    The last time notification was sent for this workflow.

    mutingRulesHandling String

    How to handle muted issues. See Muting Rules below for details.

    name String

    The name of the workflow.

    workflowId String

    The id of the workflow.

    accountId number

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinations WorkflowDestinationArgs[]

    Notification configuration. See Nested destination blocks below for details.

    destinationsEnabled boolean

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled boolean

    Whether workflow is enabled. Defaults to true.

    enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichmentsEnabled boolean

    Whether enrichments are enabled. Defaults to true.

    guid string

    Workflow entity GUID

    issuesFilter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    lastRun string

    The last time notification was sent for this workflow.

    mutingRulesHandling string

    How to handle muted issues. See Muting Rules below for details.

    name string

    The name of the workflow.

    workflowId string

    The id of the workflow.

    account_id int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinations Sequence[WorkflowDestinationArgs]

    Notification configuration. See Nested destination blocks below for details.

    destinations_enabled bool

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled bool

    Whether workflow is enabled. Defaults to true.

    enrichments WorkflowEnrichmentsArgs

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichments_enabled bool

    Whether enrichments are enabled. Defaults to true.

    guid str

    Workflow entity GUID

    issues_filter WorkflowIssuesFilterArgs

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    last_run str

    The last time notification was sent for this workflow.

    muting_rules_handling str

    How to handle muted issues. See Muting Rules below for details.

    name str

    The name of the workflow.

    workflow_id str

    The id of the workflow.

    accountId Number

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    destinations List<Property Map>

    Notification configuration. See Nested destination blocks below for details.

    destinationsEnabled Boolean

    DEPRECATED Whether destinations are enabled. Please use enabled instead: these two are different flags, but they are functionally identical. Defaults to true.

    Deprecated:

    Please use 'enabled' instead

    enabled Boolean

    Whether workflow is enabled. Defaults to true.

    enrichments Property Map

    Workflow's enrichments. See Nested enrichments blocks below for details.

    enrichmentsEnabled Boolean

    Whether enrichments are enabled. Defaults to true.

    guid String

    Workflow entity GUID

    issuesFilter Property Map

    A filter used to identify issues handled by this workflow. See Nested issues_filter blocks below for details.

    lastRun String

    The last time notification was sent for this workflow.

    mutingRulesHandling String

    How to handle muted issues. See Muting Rules below for details.

    name String

    The name of the workflow.

    workflowId String

    The id of the workflow.

    Supporting Types

    WorkflowDestination

    ChannelId string

    Id of a notification_channel to use for notifications. Please note that you have to use a notification channel, not an alert_channel.

    Name string

    The name of the workflow.

    NotificationTriggers List<string>

    Issue events to notify on. The value is a list of possible issue events. See Notification Triggers below for details.

    Type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    ChannelId string

    Id of a notification_channel to use for notifications. Please note that you have to use a notification channel, not an alert_channel.

    Name string

    The name of the workflow.

    NotificationTriggers []string

    Issue events to notify on. The value is a list of possible issue events. See Notification Triggers below for details.

    Type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    channelId String

    Id of a notification_channel to use for notifications. Please note that you have to use a notification channel, not an alert_channel.

    name String

    The name of the workflow.

    notificationTriggers List<String>

    Issue events to notify on. The value is a list of possible issue events. See Notification Triggers below for details.

    type String

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    channelId string

    Id of a notification_channel to use for notifications. Please note that you have to use a notification channel, not an alert_channel.

    name string

    The name of the workflow.

    notificationTriggers string[]

    Issue events to notify on. The value is a list of possible issue events. See Notification Triggers below for details.

    type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    channel_id str

    Id of a notification_channel to use for notifications. Please note that you have to use a notification channel, not an alert_channel.

    name str

    The name of the workflow.

    notification_triggers Sequence[str]

    Issue events to notify on. The value is a list of possible issue events. See Notification Triggers below for details.

    type str

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    channelId String

    Id of a notification_channel to use for notifications. Please note that you have to use a notification channel, not an alert_channel.

    name String

    The name of the workflow.

    notificationTriggers List<String>

    Issue events to notify on. The value is a list of possible issue events. See Notification Triggers below for details.

    type String

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    WorkflowEnrichments

    nrqls List<Property Map>

    a wrapper block

    WorkflowEnrichmentsNrql

    Configurations List<Pulumi.NewRelic.Inputs.WorkflowEnrichmentsNrqlConfiguration>

    Another wrapper block

    Name string

    The name of the workflow.

    AccountId int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    EnrichmentId string
    Type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    Configurations []WorkflowEnrichmentsNrqlConfiguration

    Another wrapper block

    Name string

    The name of the workflow.

    AccountId int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    EnrichmentId string
    Type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    configurations List<WorkflowEnrichmentsNrqlConfiguration>

    Another wrapper block

    name String

    The name of the workflow.

    accountId Integer

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    enrichmentId String
    type String

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    configurations WorkflowEnrichmentsNrqlConfiguration[]

    Another wrapper block

    name string

    The name of the workflow.

    accountId number

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    enrichmentId string
    type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    configurations Sequence[WorkflowEnrichmentsNrqlConfiguration]

    Another wrapper block

    name str

    The name of the workflow.

    account_id int

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    enrichment_id str
    type str

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    configurations List<Property Map>

    Another wrapper block

    name String

    The name of the workflow.

    accountId Number

    Determines the New Relic account in which the workflow is created. Defaults to the account defined in the provider section.

    enrichmentId String
    type String

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    WorkflowEnrichmentsNrqlConfiguration

    Query string

    An NRQL query to run

    Query string

    An NRQL query to run

    query String

    An NRQL query to run

    query string

    An NRQL query to run

    query str

    An NRQL query to run

    query String

    An NRQL query to run

    WorkflowIssuesFilter

    Name string

    The name of the workflow.

    Type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    FilterId string
    Predicates List<Pulumi.NewRelic.Inputs.WorkflowIssuesFilterPredicate>

    A condition an issue event should satisfy to be processed by the workflow

    Name string

    The name of the workflow.

    Type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    FilterId string
    Predicates []WorkflowIssuesFilterPredicate

    A condition an issue event should satisfy to be processed by the workflow

    name String

    The name of the workflow.

    type String

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    filterId String
    predicates List<WorkflowIssuesFilterPredicate>

    A condition an issue event should satisfy to be processed by the workflow

    name string

    The name of the workflow.

    type string

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    filterId string
    predicates WorkflowIssuesFilterPredicate[]

    A condition an issue event should satisfy to be processed by the workflow

    name str

    The name of the workflow.

    type str

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    filter_id str
    predicates Sequence[WorkflowIssuesFilterPredicate]

    A condition an issue event should satisfy to be processed by the workflow

    name String

    The name of the workflow.

    type String

    Type of the filter. Please just set this field to FILTER. The field is likely to be deprecated/removed in the near future.

    filterId String
    predicates List<Property Map>

    A condition an issue event should satisfy to be processed by the workflow

    WorkflowIssuesFilterPredicate

    Attribute string

    Issue event attribute to check

    Operator string

    An operator to use to compare the attribute with the provided values, see supported operators below

    Values List<string>

    The attribute must match any of the values in this list

    Attribute string

    Issue event attribute to check

    Operator string

    An operator to use to compare the attribute with the provided values, see supported operators below

    Values []string

    The attribute must match any of the values in this list

    attribute String

    Issue event attribute to check

    operator String

    An operator to use to compare the attribute with the provided values, see supported operators below

    values List<String>

    The attribute must match any of the values in this list

    attribute string

    Issue event attribute to check

    operator string

    An operator to use to compare the attribute with the provided values, see supported operators below

    values string[]

    The attribute must match any of the values in this list

    attribute str

    Issue event attribute to check

    operator str

    An operator to use to compare the attribute with the provided values, see supported operators below

    values Sequence[str]

    The attribute must match any of the values in this list

    attribute String

    Issue event attribute to check

    operator String

    An operator to use to compare the attribute with the provided values, see supported operators below

    values List<String>

    The attribute must match any of the values in this list

    Import

    Workflows can be imported using the id, e.g. bash

     $ pulumi import newrelic:index/workflow:Workflow foo <id>
    

    You can find the workflow ID from the workflow table by clicking on … at the end of the row and choosing Copy workflow id to clipboard.

    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.12.1 published on Thursday, Jun 8, 2023 by Pulumi