Skip to content

Commit

Permalink
fix(notifications): added servicenow app channel option to valid noti…
Browse files Browse the repository at this point in the history
…fication channels list (#2716)
  • Loading branch information
amaor-newrelic authored Aug 7, 2024
1 parent 13689fe commit 34698be
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 1 deletion.
1 change: 1 addition & 0 deletions newrelic/resource_newrelic_notifications_channel.go
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ func listValidNotificationsChannelTypes() []string {
string(notifications.AiNotificationsChannelTypeTypes.WEBHOOK),
string(notifications.AiNotificationsChannelTypeTypes.EMAIL),
string(notifications.AiNotificationsChannelTypeTypes.SERVICENOW_INCIDENTS),
string(notifications.AiNotificationsChannelTypeTypes.SERVICE_NOW_APP),
string(notifications.AiNotificationsChannelTypeTypes.PAGERDUTY_ACCOUNT_INTEGRATION),
string(notifications.AiNotificationsChannelTypeTypes.PAGERDUTY_SERVICE_INTEGRATION),
string(notifications.AiNotificationsChannelTypeTypes.JIRA_CLASSIC),
Expand Down
1 change: 1 addition & 0 deletions newrelic/resource_newrelic_workflow.go
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,7 @@ func listValidWorkflowsDestinationTypes() []string {
string(workflows.AiWorkflowsDestinationTypeTypes.PAGERDUTY_ACCOUNT_INTEGRATION),
string(workflows.AiWorkflowsDestinationTypeTypes.PAGERDUTY_SERVICE_INTEGRATION),
string(workflows.AiWorkflowsDestinationTypeTypes.SERVICE_NOW),
string(workflows.AiWorkflowsDestinationTypeTypes.SERVICE_NOW_APP),
string(workflows.AiWorkflowsDestinationTypeTypes.WEBHOOK),
string(workflows.AiWorkflowsDestinationTypeTypes.MOBILE_PUSH),
string(workflows.AiWorkflowsDestinationTypeTypes.SLACK),
Expand Down
13 changes: 12 additions & 1 deletion website/docs/r/notification_channel.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ The following arguments are supported:

* `account_id` - (Optional) Determines the New Relic account where the notification channel will be created. Defaults to the account associated with the API key used.
* `name` - (Required) The name of the channel.
* `type` - (Required) 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`.
* `type` - (Required) 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`.
* `destination_id` - (Required) The id of the destination.
* `product` - (Required) The type of product. One of: `DISCUSSIONS`, `ERROR_TRACKING` or `IINT` (workflows).
* `property` - A nested block that describes a notification channel property. See [Nested property blocks](#nested-property-blocks) below for details.
Expand All @@ -60,6 +60,7 @@ Each notification channel type supports a specific set of arguments for the `pro
* `SERVICENOW_INCIDENTS`
* `description` - (Optional) Free text that represents a description.
* `short_description` - (Optional) Free text that represents a short description.
* `SERVICE_NOW_APP` - No Properties.
* `JIRA_CLASSIC`, `JIRA_NEXTGEN`
* `project` - (Required) Identifier that specifies jira project id.
* `issuetype` - (Required) Identifier that specifies the issue type id.
Expand Down Expand Up @@ -112,6 +113,16 @@ resource "newrelic_notification_channel" "foo" {
}
}
```
##### [ServiceNowApp](https://docs.newrelic.com/docs/apis/nerdgraph/examples/nerdgraph-api-notifications-channels/#servicenowapp)
```hcl
resource "newrelic_notification_channel" "foo" {
account_id = 12345678
name = "servicenow-app-example"
type = "SERVICE_NOW_APP"
destination_id = "00b6bd1d-ac06-4d3d-bd72-49551e70f7a8"
product = "IINT"
}
```

##### [Email](https://docs.newrelic.com/docs/apis/nerdgraph/examples/nerdgraph-api-notifications-channels/#email)
```hcl
Expand Down

0 comments on commit 34698be

Please sign in to comment.