You can also use this library I made: https://github.com/sethkor/connect-backup
It uses the newly released AWS Connect API, you can find details here: https://docs.aws.amazon.com/connect/latest/APIReference/Welcome.html
It allows you to backup and restore contact flows plus some other AWS Connect components,
To back everything it can backup, including contact-flows type:
connect-backup --profile your-aws-profile backup --instance your-connect-instance-id --file path-to-write-backup
There are options to also write to S3.
It also comes with a Lambda and a AWS SAM template to set up periodic backup too.