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

# Replace the organization's Scan Configuration



## OpenAPI

````yaml /api-reference/earnie/platform-openapi.json put /v1/organization/scan-configuration
openapi: 3.0.3
info:
  title: Earnie Organization Settings API
  description: >-
    Read your organization, and read or change scan configuration, automatic
    scanning, pull request feedback, and local hook settings.
  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/organization/scan-configuration:
    put:
      tags:
        - organization
      summary: Replace the organization's Scan Configuration
      operationId: PutV1OrganizationScanConfiguration
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ScanConfiguration'
      responses:
        '200':
          description: Updated Scan Configuration
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScanConfiguration'
        '400':
          description: Invalid input
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Not authenticated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Insufficient permissions (requires scanconfig:write)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    ScanConfiguration:
      type: object
      description: >-
        One UI-editable layer of Scan Configuration — the organization-wide
        document or a project's document. Skip patterns and size rules exclude
        files before scanning on the next scan; Component overrides auto-resolve
        matches at scan time.
      required:
        - skip_patterns
        - skip_sizes
        - component_overrides
      properties:
        self_check_wait_seconds:
          type: integer
          minimum: 0
          maximum: 120
          description: >-
            Organization-only default synchronous Self-check wait, in seconds.
            Zero or omission uses the server default (45 seconds). A positive
            per-request wait_seconds overrides it. Project configuration cannot
            set a nonzero value. A timeout returns a running handle, not a
            failure.
        skip_patterns:
          type: array
          items:
            type: string
          description: >-
            Gitignore-style patterns excluded before scanning, unioned with
            scanner defaults and any repo scanoss.json skips.
        skip_sizes:
          type: array
          items:
            $ref: '#/components/schemas/SkipSizeRule'
          description: >-
            File-size rules excluded before scanning, unioned with any repo
            scanoss.json size rules.
        component_overrides:
          type: array
          items:
            $ref: '#/components/schemas/ComponentOverride'
        snippet_tuning:
          allOf:
            - $ref: '#/components/schemas/SnippetTuning'
          description: >-
            Snippet tuning for this layer. Optional on write, but the PUT
            replaces the whole document: a request that omits snippet_tuning
            resets every knob to inherit. Clients that edit another section must
            send back the tuning they read.
    Error:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
        message:
          type: string
    SkipSizeRule:
      type: object
      description: >-
        One file-size skip rule, spelled like a scanoss.json settings.skip.sizes
        entry. A file matching any of the patterns is skipped when it is smaller
        than min or larger than max bytes. An omitted or zero bound is no bound;
        at least one bound must be set, and min must not exceed max when both
        are.
      required:
        - patterns
      properties:
        patterns:
          type: array
          minItems: 1
          items:
            type: string
          description: Gitignore-style patterns the rule applies to.
        min:
          type: integer
          format: int64
          minimum: 0
          description: Skip matching files smaller than this many bytes.
        max:
          type: integer
          format: int64
          minimum: 0
          description: Skip matching files larger than this many bytes.
    ComponentOverride:
      type: object
      description: >-
        One Component override entry of the organization's Scan Configuration.
        The matched component is still scanned and recorded as a finding, then
        automatically resolved at scan time with an audit trail.
      required:
        - action
        - purl
      properties:
        action:
          type: string
          enum:
            - remove
            - replace
            - include
          description: >-
            remove resolves matches of the purl as "mark original"; replace
            resolves them as "replace component" with replace_with; include
            affirms a component the user declares is present, resolving matches
            as "confirm match" — the match is kept and recorded, the component
            stays in the SBOM, and gate impact is retained. include is the
            opposite of remove: it suppresses nothing.
        purl:
          type: string
          description: Component identifier the override targets (may omit @version).
        path:
          type: string
          description: Optional path scope; empty applies project-wide.
        replace_with:
          type: string
          description: >-
            Versioned replacement purl (pkg:...@version). Required when action
            is replace; must be absent for remove and include.
    SnippetTuning:
      type: object
      description: >-
        One layer's fingerprinting and match-filtering knobs, spelled like
        scanoss.json settings.file_snippet. A null field means the layer says
        nothing and inherits: the project beats the repo scanoss.json, which
        beats the organization, which beats the SDK default, decided per field.
      required:
        - skip_headers
        - skip_headers_limit
        - ranking_threshold
      properties:
        skip_headers:
          type: boolean
          nullable: true
          description: >-
            Drop each file's licence header, comments and imports from its
            fingerprint. The SDK default is on.
        skip_headers_limit:
          type: integer
          minimum: 0
          nullable: true
          description: >-
            Cap on how many leading lines skip_headers may drop; 0 is no cap.
            Rejected while skip_headers is false on the same layer.
        ranking_threshold:
          type: integer
          minimum: -1
          maximum: 10
          nullable: true
          description: >-
            Drop matches whose component ranks worse than this; 0 and -1 filter
            nothing. Applied by Earnie to the answer, so a stricter value hides
            weaker matches rather than changing what SCANOSS finds.
  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.