Prerequisites
Before using the SCANOSS API, ensure you have:- SCANOSS API key
- curl: Command-line tool (pre-installed on Linux/macOs)
- jq (optional): JSON processor for readable output
Authentication Setup
Configure your API key as an environment variable:GetComponentCpes
Retrieves Common Platform Enumeration (CPE) identifiers for a single software component identified by Package URL. CPEs are used to identify IT platforms in vulnerability databases and enable vulnerability scanning and assessment.Request Format
See Common API Types forComponentRequest documentation.
HTTP Request Example
Response Example
GetComponentsCpes
Batch version of GetComponentCpes - retrieves CPE identifiers for multiple components in a single request.Request Format
See Common API Types forComponentsRequest documentation.
HTTP Request Example
GetComponentVulnerabilities
Analyses a single software component and returns known vulnerabilities including CVE details, severity scores, publication dates, and other security metadata. Vulnerability data is sourced from various security databases and feeds.Request Format
Request Format
See Common API Types forComponentRequest documentation.
HTTP Request Example
Response Format
The method returns comprehensive vulnerability information including:purlfield: the requested componentvulnerabilitiesarray: List of known vulnerabilities affecting the componentversionfield: Shows the specific version that was analyzedrequirementfield: Echoes the client’s version constraint from the request
- CVE identifier and reference URL
- Severity classification and CVSS information
- Publication and modification dates
- Summary description
- Source database information
- CVSS array with detailed scoring information (vector, score, and severity)
CVSS Information
Thecvss field is an array of CVSS (Common Vulnerability Scoring System) objects, allowing for multiple CVSS versions or sources. Each CVSS object contains:
cvss: The CVSS vector string (e.g., “CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H”)cvss_score: The numerical CVSS score (0.0 to 10.0)cvss_severity: The severity rating based on the score (“None”, “Low”, “Medium”, “High”, “Critical”)
Response Examples
Component with Vulnerabilities
Component with No Known Vulnerabilities
GetComponentsVulnerabilities
Batch version of GetComponentVulnerabilities - analyses multiple components and returns vulnerability information for each in a single request.Request Format
See Common API Types forComponentsRequest documentation.