Closed pedrocarrico closed 1 month ago
I don't think you can set that integration that way. They have some examples on how to fetch this in their docs here.
resource "pagerduty_service_integration" "apiv2" {
name = "API V2"
type = "events_api_v2_inbound_integration"
service = pagerduty_service.example.id
}
The above should create a pagerduty service which you should be able to output with something like:
output "integration_key" {
description = "The integration key for the PagerDuty service."
value = sensitive(pagerduty_service_integration.apiv2.integration_key)
sensitive = true
}
Thanks @cavila-evoliq! Yeah that seems to work well!
Hi,
I'm trying to get the details of a PagerDuty vendor to create a service integration but when I fetch with the name "Events API v2" I get the details for "PRTG Notification For PagerDuty Events API v2". The "Events API v2" integration is done by PageDuty not an external vendor so probably that integration isn't possible to be fetched from this API? How can I fetch via terraform the details for this integration type so I can create a service integration correctly?
Terraform Version
v1.8.5
Affected Resource(s)
pagerduty_vendor on version 3.15.6
Terraform Configuration Files
Expected Behavior
On that data resource I should get the "Events API v2" vendor and integration details.
Actual Behavior
I got the "PRTG Notification For PagerDuty Events API v2" vendor and integration details.
Steps to Reproduce
Use the data resource, see that if fetches the wrong vendor for the integration.
Important Factoids
References