Use CLI for static scanning
Instead of using the Contrast web interface, you can use the CLI to scan your code.
Before you begin
Learn about the Contrast CLI.
Steps
Store your Contrast credentials locally with this command in a terminal window:
contrast auth --api-key <ContrastAPIKey> --authorization <ContrastAuthorizationHeader> --host <YourHosDomain> --organization id <ContrastOrganizationID>
Get the Contrast API key, the authorization header, and organization ID by logging into the Contrast web interface and selecting user menu > User settings.
Upload and scan a package by using this command in a terminal window:
contrast scan --file <FileName>
CLI commands describes all the valid options for the scan
command.