hcp_notifications_webhook (Resource)

The webhook resource manages a HCP webhook, used to notify external systems about a project resource's lifecycle events

Example Usage

resource "hcp_notifications_webhook" "example" {
  name        = "example-webhook"
  description = "Notify for all of the events for all Packer artifact versions existing in the project."

  config = {
    url = "https://example.com"
  }

  subscriptions = [
    {
      events = [
        {
          actions = ["*"]
          source  = "hashicorp.packer.version"
        }
      ]
    }
  ]
}

Schema

Required

Optional

Read-Only

Nested Schema for config

Required:

Optional:

Nested Schema for subscriptions

Required:

Optional:

Nested Schema for subscriptions.events

Required:

Import

Import is supported using the following syntax:

# HCP Webhook can be imported by specifying the webhook resource name
# The webhook resource name is in the format webhook/project/{project_id}/geo/us/webhook/{webhook_name}
terraform import hcp_notifications_webhook.example webhook/project/840e3701-55b6-4f86-8c17-b1fe397303c5/geo/us/webhook/example-webhook