When I use AWS's CLI to get a security certificate for a IoT Thing I enter:
aws iot describe-certificate --certificate-id myCertificateId --output text --query certificateDescription.certificatePem > cert.pem
but I get
usage: aws [options] [parameters] aws: error: argument command: Invalid choice, valid choices are: ...(something)
However, cert.pem file was created, but it's empty. Also, the certificate did show up in the AWS IoT console with the correct myCertificateId.
Did it work correctly? Is something wrong with the AWS CLI args parameter error handling?