Genesys Cloud - Developer Community!

 View Only

Sign Up

  • 1.  Error when using MyPureCloud/genesyscloud Terraform module

    Posted 6 days ago

    Good afternoon, 

    I want to start using terrafom to manage and maintain my Architect flows. I was able to setup MyPureCloud/genesyscloud and am able to pull my flows and store them as .yaml files. 

    The issue is when I try and push my flow back to Genesys (even without making any changes). The inbound call flow I am using has "call Audio Connector" nodes in it. 
    As soon as I try and push it back to Genesys I get this error:

    find 'audio connector' by value of 'Name - prod' - Failed to find item Name - prod. -- [ArchNetworkValueRetrieval]

    │ promise unhandled exception caught.  Error: could not find the 'audio connector' by name using the value 'Name - prod'.
    │ Error details: Failed to fetch audio connector bots. -- [ArchAsyncTracker]

    │ could not find the 'audio connector' by name using the value 'Name prod'.
    │ Error details: Failed to fetch audio connector bots.

    If this was an permissions error I would expect a different error. Anybody have any experience with this? I have exported the flow from the architect UI and compared it to the one I pulled with Terraform and they are identical. 

    Regards, Michael 


    #Architect

    ------------------------------
    Michael Bessels
    ------------------------------


  • 2.  RE: Error when using MyPureCloud/genesyscloud Terraform module

    Posted 6 days ago
    Edited by Breno Canyggia Ferreira Marreco 6 days ago

    Hi Michael, I can think of three possible situations:

    1. What version are you using? I ask because support for the "Call Audio Connector" action was added in Archy version 2.28: https://developer.genesys.cloud/devapps/archy/changelog
    2. Are you moving flows between environments (Dev/Homologation and Prod)? If so, the Audio Connector Bot name may be different in each environment. You might need to translate or map environment-specific values in your Terraform files (dev, hom, prod).
    3. I have experienced issues when exporting flows manually from the Architect UI. Since then, I always export flows using Archy instead of the UI. It might be worth testing whether exporting and importing the flow exclusively through Archy changes the behavior.

      Based on the error message, it seems that Archy/Terraform is unable to resolve the Audio Connector Bot named "Name - prod" during the publish process. I would verify that the bot exists in the target org and that the account used by Terraform has permission to retrieve Audio Connector Bots. Hope this helps.



    ------------------------------
    Att,
    Breno Canyggia Ferreira Marreco
    ------------------------------



  • 3.  RE: Error when using MyPureCloud/genesyscloud Terraform module

    Posted 6 days ago

    Hi Michael,

    I am starting to look into Terraform so this type of thing is really interesting to us. Hopefully you get it resolved based on Brenos reply, but seeing others using Terraform and identifying any issues, resolutions and best practices is always helpful.

    thanks



    ------------------------------
    lee fairweather
    Solution Architect
    ------------------------------



  • 4.  RE: Error when using MyPureCloud/genesyscloud Terraform module

    Posted 2 days ago

    Hi @Michael Bessels

    One additional thing worth checking is whether the Terraform provider is resolving the Audio Connector by name during the publish process rather than by the underlying resource ID.


    I've seen similar situations with Architect resources where the flow export looks identical, but during deployment Archy performs a validation lookup against the target org and fails if the referenced object cannot be resolved exactly as expected.


    A few things I would verify:


    Confirm that the Audio Connector Bot exists and is active in the same org where Terraform is publishing the flow.
    Check for any differences in naming, including leading/trailing spaces, case sensitivity, or recent renames.
    Review the exported YAML and verify whether the Audio Connector reference is stored as a display name instead of a stable ID.
    Try exporting and re-importing a very simple test flow containing only a single "Call Audio Connector" action. If the issue reproduces there, it may indicate a provider/Archy limitation rather than a problem with the flow itself.


    If the flow was exported from the same environment and fails without modifications, I would also suspect a provider bug or a gap in Audio Connector support within the Terraform/Archy workflow. It might be worth enabling DEBUG logging (TF_LOG=DEBUG) and reviewing the API calls made during the publish operation to see exactly which lookup is failing.


    Interested to know whether the deployment succeeds if the "Call Audio Connector" action is temporarily removed from the flow. That could help isolate whether the issue is specific to Audio Connector resolution.



    ------------------------------
    Cesar Padilla
    INDRA COLOMBIA
    ------------------------------