AWS CLI - All commands return Unknown output type: [None]

Run the command "aws configure", then check if the word "JSON" in "Default output format [JSON]:" is in upper case or lower case? If it's in upper case then running any aws command shows "Unknown ouput type : JSON".
Or alternately open the file C:\Users\<user>\.aws\config file and check the entry "output = json". If the word json is in upper case then running any aws command shows "Unknown ouput type : JSON".

Solution:
Replace the upper case JSON with lower case json.


$aws configure
press Enters
see the "Default output format [None]:" 
input one of "json, text or table "(all in lower case) 
after that rerun your command. 

My ~/.aws/config was somehow in a bad state, there were multiple declarations for the same setting under a single role header. Editing the file manually fixed my issue.

The info under Configuration Settings and Precedence https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html led me to the right place.

Tags:

Aws Cli