Newer Version Available
Support for JSON Responses
Salesforce CLI commands typically display their output to the console (stdout) in
non-structured, human-readable format. Messages written to the log file (stderr) are always in JSON format.
To view the console output in JSON format, specify the --json parameter for a particular CLI command.
1sfdx force:org:display --jsonMost CLI commands support JSON output. To confirm, run the command with the --help parameter to view the supported parameters.
To get JSON responses to all Salesforce CLI commands without specifying the --json option each time, set the SFDX_CONTENT_TYPE environment variable.
1export SFDX_CONTENT_TYPE=JSON