> ## 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.

# Search the SCANOSS component knowledgebase



## OpenAPI

````yaml /api-reference/earnie/components-openapi.json get /v1/components
openapi: 3.0.3
info:
  title: Earnie Component Catalog API
  description: Search the SCANOSS knowledge base component catalog.
  version: 1.0.0
servers:
  - url: https://{tenant}.earnie.dev
    description: Your Earnie deployment
    variables:
      tenant:
        default: your-company
        description: >-
          Your organization's Earnie address, as shown in your browser when you
          sign in.
security:
  - bearerAuth: []
paths:
  /v1/components:
    get:
      summary: Search the SCANOSS component knowledgebase
      operationId: getV1Components
      parameters:
        - name: q
          in: query
          required: true
          schema:
            type: string
            minLength: 1
        - name: limit
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 50
            default: 10
        - name: offset
          in: query
          schema:
            type: integer
            minimum: 0
            default: 0
      responses:
        '200':
          description: Matching component candidates.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComponentSearchResponse'
        '400':
          description: Invalid query.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComponentSearchError'
        '502':
          description: SCANOSS knowledgebase request failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComponentSearchError'
components:
  schemas:
    ComponentSearchResponse:
      type: object
      required:
        - items
        - limit
        - offset
        - has_more
      properties:
        items:
          type: array
          items:
            $ref: '#/components/schemas/ComponentCandidate'
        limit:
          type: integer
        offset:
          type: integer
        has_more:
          type: boolean
          description: True when the page is full and another page may exist.
    ComponentSearchError:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
        message:
          type: string
    ComponentCandidate:
      type: object
      required:
        - purl
        - name
        - vendor
        - versions
        - versions_status
      properties:
        purl:
          type: string
          description: Base package URL for the component.
        name:
          type: string
        vendor:
          type: string
          nullable: true
          description: Package URL namespace when present.
        url:
          type: string
          nullable: true
          description: >-
            Project URL as reconstructed by the knowledgebase. Null when the
            knowledgebase reports none — it is not guaranteed for every
            component.
        versions:
          type: array
          items:
            $ref: '#/components/schemas/ComponentVersion'
          description: >-
            Known versions, newest first. Always empty when versions_status is
            `unavailable`.
        versions_status:
          type: string
          enum:
            - resolved
            - unavailable
          description: >-
            Whether `versions` can be trusted as complete. `resolved` — the
            version lookup succeeded, so an empty array means the component
            genuinely has no known versions. `unavailable` — the per-component
            version lookup failed, so the array is empty because nothing is
            known, not because nothing exists. Clients must not present an
            `unavailable` candidate as having no versions.
        license:
          type: string
          nullable: true
          description: >-
            SPDX identifier or license name from the newest known version — the
            same value as versions[0].license. Null when unknown or when
            versions_status is `unavailable`.
    ComponentVersion:
      type: object
      required:
        - version
      properties:
        version:
          type: string
          description: Version string exactly as the knowledgebase records it.
        date:
          type: string
          nullable: true
          description: >-
            Release date as reported by the upstream registry. The format is
            registry-defined and deliberately not normalised, so treat it as an
            opaque label rather than a parseable timestamp. Null when unknown.
        license:
          type: string
          nullable: true
          description: >-
            SPDX identifier for this specific version when the knowledgebase has
            one, otherwise the upstream license name. Null when unknown.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        An Earnie API key, sent as `Authorization: Bearer sk_earnie_...`. Create
        one under Settings > API keys. The key's scopes decide which operations
        it may call.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.