We’re migrating our Genesys Cloud infrastructure to Terraform, and I’m hitting a wall trying to import existing routing queues. The genesyscloud_routing_queue resource seems straightforward, but terraform import keeps failing with a 404 Not Found error, even though the queue exists and I can query it via the API.
I’ve verified the queue ID using the REST API:
GET https://api.mypurecloud.com/api/v2/routing/queues/12345678-abcd-efgh-ijkl-1234567890ab
The response returns 200 OK with the full queue details. However, when I run:
terraform import genesyscloud_routing_queue.main 12345678-abcd-efgh-ijkl-1234567890ab
I get:
Error: 404 Not Found
My Terraform configuration looks like this:
resource "genesyscloud_routing_queue" "main" {
name = "Support Queue"
description = "Main support queue"
enable_presence_based_routing = true
outbound_wrap_up_policy = "immediate"
member_flow {
type = "longest_idle"
}
queue_flow {
type = "longest_idle"
}
}
I’ve checked the provider version (1.30.0) and the docs mention that some resources require specific attributes to be present for import to succeed. I’ve tried adding outbound_wrap_up_policy and member_flow blocks, but it doesn’t help.
Is there something specific about how the Genesys Cloud provider handles queue imports? Or is there a different endpoint it’s trying to call that’s failing? I’ve enabled debug logging, but it just shows the 404 response without much detail on what exactly it’s trying to fetch.
Here’s a snippet from the debug log:
{
"@timestamp": "2023-10-25T14:32:10.123Z",
"level": "DEBUG",
"message": "GET /api/v2/routing/queues/12345678-abcd-efgh-ijkl-1234567890ab returned 404",
"request_id": "abc-123-def"
}
I’ve also tried using the genesyscloud_routing_skill_group resource for comparison, and imports work fine there. So it’s not an authentication or network issue.
Any ideas what might be causing this? I’ve spent two hours on this and I’m out of ideas.