Terraform data source lookup failing on existing CXone routing queue by name

Trying to reference an existing CXone routing queue in a new Terraform module without hardcoding the ID. The queue was created manually in the console, so I can’t use the resource block.

Using the genesyscloud_routing_queue data source to look it up by name.

terraform {
 required_providers {
 genesyscloud = {
 source = "mygenesys/genesyscloud"
 }
 }
}

data "genesyscloud_routing_queue" "existing_queue" {
 name = "Support Tier 1"
}

resource "genesyscloud_routing_skill_group" "new_sg" {
 name = "Test SG"
 # ... other config
}

Running terraform plan throws this error:

Error: 1 error occurred:
	* No matching routing queue found for name "Support Tier 1"

I’ve verified the name is exact. Checked the console, no typos. The queue exists and is active.

Tried adding search_pattern = true to the data source block. Didn’t help. Still the same error.

Also tried wrapping the name in quotes inside the HCL string. Same result.

Checked the provider docs. It says the name attribute should be sufficient for lookup. But it seems like it’s doing an exact match and failing.

Is there a specific attribute I need to set to allow partial matches? Or maybe the data source is case-sensitive and the console has a trailing space I can’t see?

Looking at the debug logs, the API call goes to /api/v2/routing/queues. The response comes back with the queue, but Terraform discards it.

Any ideas on how to force the lookup to work? Or should I just script the ID fetch separately?