---
title: "uptimeify_notification_channel"
description: "A notification channel of the organization, or of one customer with customer_id. Secrets live in secret_config_wo and never enter the state. An active channel to the same recipient cannot exist twice (409). Website overrides are not managed here. Import with the numeric id."
---

A notification channel of the organization, or of one customer with `customer_id`. Secrets live in `secret_config_wo` and never enter the state. An active channel to the same recipient cannot exist twice (409). Website overrides are not managed here. Import with the numeric id.

## Example Usage

```terraform
resource "uptimeify_notification_channel" "ops_mail" {
  type   = "email"
  name   = "Ops mail"
  config = jsonencode({ email = "ops@example.com" })
}

# Secrets go into the write-only attribute; bump the version to send a new one.
variable "slack_webhook_url" {
  type      = string
  sensitive = true
}

resource "uptimeify_notification_channel" "slack" {
  type                     = "slack"
  category                 = "integration"
  name                     = "Slack #alerts"
  customer_id              = tonumber(uptimeify_customer.shop.id)
  config                   = jsonencode({})
  secret_config_wo         = jsonencode({ webhookUrl = var.slack_webhook_url })
  secret_config_wo_version = 1
}
```

## Schema

### Required

- `config` (String) Provider settings without secrets, as a JSON object (`jsonencode({ email = "ops@example.com" })`). Keys removed here are cleared.
- `name` (String)
- `type` (String) Channel type: `email`, `sms`, `webhook`, `incident_management`, `slack`, `discord`, `teams`, `pagerduty`, `pushover`, `opsgenie`, `matrix`, `jira`, `allquiet`, `telegram`, `googlechat`, `mattermost`, `rocketchat`, `ntfy`, `gotify`, `ilert`, `grafanaoncall`, `incidentio`, `squadcast`, `github`, `gitlab`, `linear`, `servicenow`, `lark`, `dingtalk`, `wecom`.

### Optional

> **NOTE**: [Write-only arguments](https://developer.hashicorp.com/terraform/language/resources/ephemeral#write-only-arguments) are supported in Terraform 1.11 and later.

- `allowed_package_types` (Set of String) Only customers with these package types get this channel. Unset = all packages.
- `category` (String) `direct` (default) or `integration`.
- `conditions` (String) Delivery conditions as a JSON object. Unset = always.
- `customer_id` (Number) Channel of this customer. Unset = organization channel.
- `delay_seconds` (Number) Wait before sending, 0 to 86400 seconds.
- `is_active` (Boolean)
- `secret_config_wo` (String, Sensitive, [Write-only](https://developer.hashicorp.com/terraform/language/resources/ephemeral#write-only-arguments)) Write-only secret settings as a JSON object, stored encrypted. Sent with create and whenever `secret_config_wo_version` changes; keys left out keep their stored value. A secret cannot be removed (the API keeps the old value), replace the channel instead. Secret keys per type: `allquiet`: `webhookUrl`; `dingtalk`: `webhookUrl`; `discord`: `secret`, `webhookUrl`, `url`; `github`: `token`; `gitlab`: `token`; `googlechat`: `webhookUrl`; `gotify`: `appToken`; `grafanaoncall`: `webhookUrl`; `ilert`: `integrationKey`; `incidentio`: `token`; `jira`: `apiToken`; `lark`: `webhookUrl`; `linear`: `apiKey`; `matrix`: `accessToken`; `mattermost`: `webhookUrl`; `ntfy`: `accessToken`; `opsgenie`: `apiKey`; `pagerduty`: `routingKey`; `pushover`: `userKey`, `apiToken`; `rocketchat`: `webhookUrl`; `servicenow`: `password`; `slack`: `secret`, `webhookUrl`, `url`; `squadcast`: `webhookUrl`; `teams`: `webhookUrl`, `url`; `telegram`: `botToken`; `webhook`: `secret`, `webhookHeaders`, `headers`; `wecom`: `webhookUrl`.
- `secret_config_wo_version` (Number) Change to resend `secret_config_wo`.

### Read-Only

- `created_at` (String)
- `id` (String) Numeric channel id.
- `organization_id` (Number)
- `secrets_set` (Map of Boolean) Which secrets are stored, e.g. `{ Secret = true }` (the API's `has<Secret>` flags).

## Import

Import is supported using the following syntax:

The [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import) can be used, for example:

```shell
terraform import uptimeify_notification_channel.ops_mail 42
```
