| page_title | dbtcloud_model_notifications Resource - dbtcloud |
|---|---|
| subcategory | |
| description | Configure model notifications for a dbt Cloud environment. By default all the on_... are set to false. When destroyed, the model notifications are disabled. |
Configure model notifications for a dbt Cloud environment. By default all the on_... are set to false. When destroyed, the model notifications are disabled.
resource "dbtcloud_model_notifications" "prod_model_notifications" {
environment_id = dbtcloud_environment.prod_environment.environment_id
enabled = true
on_success = false
on_failure = true
on_warning = true
}environment_id(String) The ID of the dbt Cloud environment
enabled(Boolean) Whether model notifications are enabled for this environmenton_failure(Boolean) Whether to send notifications for failed model runson_skipped(Boolean) Whether to send notifications for skipped model runson_success(Boolean) Whether to send notifications for successful model runson_warning(Boolean) Whether to send notifications for model runs with warningsresource_metadata(Dynamic) Metadata for tracking resource identity during account migrations. Stored in Terraform state only and not sent to the API.
id(String) The internal ID of the model notifications configuration
Import is supported using the following syntax:
# Model notifications are imported using the environment ID where the notifications are enabled
# Using import blocks (requires Terraform >= 1.5)
import {
to = dbtcloud_model_notifications.my_model_notifications
id = "environment_id"
}
import {
to = dbtcloud_model_notifications.my_model_notifications
id = "12345"
}
# Using the older import command
terraform import dbtcloud_model_notifications.my_model_notifications "environment_id"
terraform import dbtcloud_model_notifications.my_model_notifications 12345