Terraform CX as Code provider failing to apply queue with skills defined in resource block

We’re trying to manage our Genesys Cloud queues via Terraform using the CX as Code provider. The goal is to define a queue with specific skills and wrap-up codes directly in the state file rather than relying on manual UI configuration. We have the provider version pinned to 1.5.0 and our organization is set up with the required OAuth credentials.

The issue arises when we try to define skills within the genesyscloud_queue resource. The documentation for the provider is sparse on complex nested objects like skills. We’ve tried mapping the skill IDs directly, but the apply step consistently fails with a 400 Bad Request error from the Genesys Cloud API. The error message returned is vague, just saying “Invalid request body”.

Here’s the relevant snippet from our main.tf:

resource "genesyscloud_queue" "support_queue" {
 name = "Support Queue"
 description = "General support queue"
 
 skills {
 skill_id = "12345678-1234-1234-1234-123456789abc"
 name = "Billing"
 }
}

We’ve verified that the skill_id exists and is active in our org. We can see it in the UI. When we remove the skills block, the queue creates successfully. Adding it back causes the failure. We’ve also tried using the genesyscloud_skill data source to reference the skill, but that doesn’t seem to change the outcome.

Is there a specific schema requirement for the skills block in the CX as Code provider? Or are we missing a required field like level or priority? We’ve checked the OpenAPI spec for /api/v2/iam/queues, but the Terraform provider abstraction seems to map differently. Any insights on the correct structure for defining skills in this resource would be appreciated. We’re stuck on this and need to get the infrastructure as code pipeline moving.