I am unable to move my latest version of a flow to another environment. The latest version is number 29.
When I use this command:
sfdx force:source:retrieve -m "Flow:My_Flow-29" -u dev
I get the this response:
=== Retrieved Source
FULL NAME TYPE PROJECT PATH
──────────────────────────────────────── ─────────── ─────────────────────────────────────────────────────────────────────────────────────────────
My_Flow Flow force-app/main/default/flows/My_Flow.flow-meta.xml
When I try to deploy I use this command:
sfdx force:source:deploy -m "Flow:My_Flow-29" -u staging
I get the following response:
=== Deployed Source
No results found
If I try the same above but without specifying the version number (i.e. sfdx force:source:deploy -m "Flow:My_Flow"
) I am then able to retrieve, but when I deploy I get the following error:
Invalid version number: 26
TYPE PROJECT PATH PROBLEM
───── ────────────────────────────────────────────────────────────────────────────── ──────────────────────────
Error force-app/main/default/flowDefinitions/My_Flow.flowDefinition-meta.xml Invalid version number: 26
How do I use the metadata API to upload the latest version of my flow?
<activeVersionNumber></activeVersionNumber>
tag from the flowDefinition file and try deploying again.