dokploy_resend_notification (Resource)
A Resend notification channel (Settings > Notifications). Dokploy sends each message as an email through the Resend API.
Each event attribute selects one Dokploy event that sends a message on this channel. All events default to false, so a new channel sends nothing until you enable one.
~> Dokploy does not test the channel on create or update. A wrong URL or token applies successfully and fails on the first message.
~> Dokploy stores and returns api_key in cleartext. The attribute is sensitive, so Terraform does not print it, but anyone with API access to the server can read it. The api_key_wo companion keeps it out of the Terraform state.
Example Usage
# Email through Resend, from a domain that Resend verified.
resource "dokploy_resend_notification" "ops" {
name = "ops-resend"
from_address = "[email protected]"
to_addresses = ["[email protected]"]
api_key_wo = var.resend_api_key
api_key_wo_version = 1
app_build_error = true
database_backup = true
}Schema
Required
from_address(String) Sender address on a domain that Resend verified.name(String) Display name. Dokploy does not enforce a unique name.to_addresses(List of String) Recipient addresses. At least one.
Optional
NOTE: Write-only arguments are supported in Terraform 1.11 and later.
api_key(String, Sensitive) Resend API key. Set this attribute orapi_key_wo.api_key_wo(String, Sensitive, Write-only) Write-only form ofapi_key. Terraform keeps it out of the plan and the state. It needs Terraform 1.11 or later. Set exactly one ofapi_keyandapi_key_wo. A new value reaches the server only whenapi_key_wo_versionchanges.api_key_wo_version(Number) Version ofapi_key_wo. Change it to send the currentapi_key_wovalue to the server. It needsapi_key_wo.app_build_error(Boolean) Send a message when a build fails. Defaults tofalse.app_deploy(Boolean) Send a message when an application or a compose deploys. Defaults tofalse.database_backup(Boolean) Send a message when a database backup runs. Defaults tofalse.docker_cleanup(Boolean) Send a message when the Docker cleanup runs. Defaults tofalse.dokploy_backup(Boolean) Send a message when the Dokploy server backup runs. Defaults tofalse.dokploy_restart(Boolean) Send a message when Dokploy restarts. Defaults tofalse.server_threshold(Boolean) Send a message when a server crosses a resource threshold. Defaults tofalse.volume_backup(Boolean) Send a message when a volume backup runs. Defaults tofalse.
Read-Only
created_at(String) Creation timestamp from the server.id(String) Notification id.
Import
Import is supported using the following syntax:
The terraform import command can be used, for example:
terraform import dokploy_resend_notification.example INt_PYqh9apo8mmDIoixZ