Safety can output the result of a vulnerability scan to a variety of different output formats.
The default output is screen output, which prints the scan to the command line screen.
Use the --output argument to configure which output format Safety generates. The --output command line argument can be set to the following values: screen, json, html, spdx, [email protected], [email protected], none.
Screen and text output
--output screen (default) will print the results to the screen
Results can be easily saved to a text file. For example:
safety scan --output screen > results.txt
For more detailed output, add the --detailed-output flag
If --detailed-output is specified along with --output json then CVE details will be included in the output. In order to filter the json output to only 1 top-level key, the --filter option can be specified. For example: