Is it possible to export all Architect flows as JSON using the CX as Code CLI?
I am setting up a local Docker Compose environment to mirror our production Genesys Cloud instance for integration testing. I need to pull down the current state of all Architect flows to seed my mock API server. I am using the genesys-cloud-cli (CX as Code) tool.
I have tried running the following command in my container:
gc-cli architect:flow:get --id 1234567890 --output json > flow.json
This works for a single flow, but I have hundreds of flows. I need a way to iterate through them all programmatically or export them in bulk.
Steps to reproduce:
- Authenticate using
gc-cli auth:login --mode apiwith a service account. - Attempt to list all flows using
gc-cli architect:flow:list. - Try to pipe the output to a bulk export command.
The list command returns a summary, but not the full JSON definition required for the Terraform provider or my mock server. There is no obvious export-all flag in the documentation.
Can I chain the list output with a loop to fetch each flow’s JSON, or is there a hidden API endpoint I should be hitting directly via the CLI?