id) {
var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder()
.version(Utilities.getVersion())
diff --git a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannel.java b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannel.java
index ae7e01ef..6e9055a5 100644
--- a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannel.java
+++ b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannel.java
@@ -122,6 +122,43 @@
* }
*
* <!--End PulumiCodeChooser -->
+ * ##### [ServiceNowApp](https://docs.newrelic.com/docs/apis/nerdgraph/examples/nerdgraph-api-notifications-channels/#servicenowapp)
+ * <!--Start PulumiCodeChooser -->
+ *
+ * {@code
+ * package generated_program;
+ *
+ * import com.pulumi.Context;
+ * import com.pulumi.Pulumi;
+ * import com.pulumi.core.Output;
+ * import com.pulumi.newrelic.NotificationChannel;
+ * import com.pulumi.newrelic.NotificationChannelArgs;
+ * 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 NotificationChannel("foo", NotificationChannelArgs.builder()
+ * .accountId(12345678)
+ * .name("servicenow-app-example")
+ * .type("SERVICE_NOW_APP")
+ * .destinationId("00b6bd1d-ac06-4d3d-bd72-49551e70f7a8")
+ * .product("IINT")
+ * .build());
+ *
+ * }
+ * }
+ * }
+ *
+ * <!--End PulumiCodeChooser -->
*
* ##### [Email](https://docs.newrelic.com/docs/apis/nerdgraph/examples/nerdgraph-api-notifications-channels/#email)
* <!--Start PulumiCodeChooser -->
@@ -714,14 +751,14 @@ public Output status() {
return this.status;
}
/**
- * The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
+ * The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
*
*/
@Export(name="type", refs={String.class}, tree="[0]")
private Output type;
/**
- * @return The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
+ * @return The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
*
*/
public Output type() {
@@ -750,13 +787,20 @@ public NotificationChannel(String name, NotificationChannelArgs args) {
* @param options A bag of options that control this resource's behavior.
*/
public NotificationChannel(String name, NotificationChannelArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
- super("newrelic:index/notificationChannel:NotificationChannel", name, args == null ? NotificationChannelArgs.Empty : args, makeResourceOptions(options, Codegen.empty()));
+ super("newrelic:index/notificationChannel:NotificationChannel", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()));
}
private NotificationChannel(String name, Output id, @Nullable NotificationChannelState state, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("newrelic:index/notificationChannel:NotificationChannel", name, state, makeResourceOptions(options, id));
}
+ private static NotificationChannelArgs makeArgs(NotificationChannelArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
+ if (options != null && options.getUrn().isPresent()) {
+ return null;
+ }
+ return args == null ? NotificationChannelArgs.Empty : args;
+ }
+
private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) {
var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder()
.version(Utilities.getVersion())
diff --git a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannelArgs.java b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannelArgs.java
index e642b33e..abddbaec 100644
--- a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannelArgs.java
+++ b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationChannelArgs.java
@@ -110,14 +110,14 @@ public Output> properties() {
}
/**
- * The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
+ * The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
*
*/
@Import(name="type", required=true)
private Output type;
/**
- * @return The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
+ * @return The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
*
*/
public Output type() {
@@ -291,7 +291,7 @@ public Builder properties(NotificationChannelPropertyArgs... properties) {
}
/**
- * @param type The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
+ * @param type The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
*
* @return builder
*
@@ -302,7 +302,7 @@ public Builder type(Output type) {
}
/**
- * @param type The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
+ * @param type The type of channel. One of: `EMAIL`, `SERVICENOW_INCIDENTS`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA_CLASSIC`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `SLACK` and `SLACK_COLLABORATION`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`.
*
* @return builder
*
diff --git a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestination.java b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestination.java
index e7e7d0ac..6affa851 100644
--- a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestination.java
+++ b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestination.java
@@ -248,16 +248,18 @@ public Output status() {
return this.status;
}
/**
- * (Required) The type of the destination. One of: (WEBHOOK, EMAIL, SERVICE_NOW, PAGERDUTY_ACCOUNT_INTEGRATION,
- * PAGERDUTY_SERVICE_INTEGRATION, JIRA, SLACK, SLACK_COLLABORATION, SLACK_LEGACY, MOBILE_PUSH, EVENT_BRIDGE).
+ * (Required) The type of the destination. One of: (WEBHOOK, EMAIL, SERVICE_NOW, SERVICE_NOW_APP,
+ * PAGERDUTY_ACCOUNT_INTEGRATION, PAGERDUTY_SERVICE_INTEGRATION, JIRA, SLACK, SLACK_COLLABORATION, SLACK_LEGACY,
+ * MOBILE_PUSH, EVENT_BRIDGE).
*
*/
@Export(name="type", refs={String.class}, tree="[0]")
private Output type;
/**
- * @return (Required) The type of the destination. One of: (WEBHOOK, EMAIL, SERVICE_NOW, PAGERDUTY_ACCOUNT_INTEGRATION,
- * PAGERDUTY_SERVICE_INTEGRATION, JIRA, SLACK, SLACK_COLLABORATION, SLACK_LEGACY, MOBILE_PUSH, EVENT_BRIDGE).
+ * @return (Required) The type of the destination. One of: (WEBHOOK, EMAIL, SERVICE_NOW, SERVICE_NOW_APP,
+ * PAGERDUTY_ACCOUNT_INTEGRATION, PAGERDUTY_SERVICE_INTEGRATION, JIRA, SLACK, SLACK_COLLABORATION, SLACK_LEGACY,
+ * MOBILE_PUSH, EVENT_BRIDGE).
*
*/
public Output type() {
@@ -286,13 +288,20 @@ public NotificationDestination(String name, NotificationDestinationArgs args) {
* @param options A bag of options that control this resource's behavior.
*/
public NotificationDestination(String name, NotificationDestinationArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
- super("newrelic:index/notificationDestination:NotificationDestination", name, args == null ? NotificationDestinationArgs.Empty : args, makeResourceOptions(options, Codegen.empty()));
+ super("newrelic:index/notificationDestination:NotificationDestination", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()));
}
private NotificationDestination(String name, Output id, @Nullable NotificationDestinationState state, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("newrelic:index/notificationDestination:NotificationDestination", name, state, makeResourceOptions(options, id));
}
+ private static NotificationDestinationArgs makeArgs(NotificationDestinationArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
+ if (options != null && options.getUrn().isPresent()) {
+ return null;
+ }
+ return args == null ? NotificationDestinationArgs.Empty : args;
+ }
+
private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) {
var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder()
.version(Utilities.getVersion())
diff --git a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestinationArgs.java b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestinationArgs.java
index 818aa211..3db80b80 100644
--- a/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestinationArgs.java
+++ b/sdk/java/src/main/java/com/pulumi/newrelic/NotificationDestinationArgs.java
@@ -144,16 +144,18 @@ public Optional