Skip to main content
POST
/
v2
/
licenses
/
components
Get license information for multiple software components in a single request.
curl --request POST \
  --url http://api.scanoss.com/v2/licenses/components \
  --header 'Content-Type: application/json' \
  --data '
{
  "components": [
    {
      "purl": "pkg:github/scanoss/engine@1.0.0"
    },
    {
      "purl": "pkg:github/scanoss/scanoss.py@v1.30.0"
    }
  ]
}
'
{
  "components": [
    {
      "purl": "pkg:github/scanoss/engine@1.0.0",
      "requirement": "",
      "version": "1.0.0",
      "statement": "GPL-2.0",
      "licenses": [
        {
          "id": "GPL-2.0",
          "full_name": "GNU General Public License v2.0 only",
          "is_spdx_approved": true,
          "url": "https://spdx.org/licenses/GPL-2.0-only.html"
        }
      ],
      "url": "https://github.com/scanoss/engine"
    },
    {
      "purl": "pkg:github/scanoss/scanoss.py@v1.30.0",
      "requirement": "",
      "version": "v1.30.0",
      "statement": "MIT",
      "licenses": [
        {
          "id": "MIT",
          "full_name": "MIT License",
          "is_spdx_approved": true,
          "url": "https://spdx.org/licenses/MIT.html"
        }
      ],
      "url": "https://github.com/scanoss/scanoss.py"
    }
  ],
  "status": {
    "status": "SUCCESS",
    "message": "Licenses Successfully retrieved"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.scanoss.com/llms.txt

Use this file to discover all available pages before exploring further.

Body

application/json

Represents a list of software component to be analyzed by SCANOSS API services. Allows analysis of multiple software components in a single API call, improving performance over individual requests.

Represents a list of software component to be analyzed by SCANOSS API services. Allows analysis of multiple software components in a single API call, improving performance over individual requests.

components
Array of component requests to analyze · object[]
required

Response

A successful response.

Success example. For error cases, each component block reports the failure via info_message and info_code. Example: {"components":[{"purl":"pkg:github/scanoss/unknown-component","requirement":"","version":"","statement":"","licenses":[],"url":"","info_message":"Component version not found","info_code":"VERSION_NOT_FOUND"}],"status":{"status":"SUCCESS","message":"Success"}}

components
License info for each component in the batch · object[]
status
object

Detailed response details.