> ## Documentation Index
> Fetch the complete documentation index at: https://veridical-dev.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Scan



## OpenAPI

````yaml /openapi.json post /api/v1/scans
openapi: 3.1.0
info:
  title: Veridical API
  version: 1.0.0
servers:
  - url: https://api.veridical.dev
security: []
paths:
  /api/v1/scans:
    post:
      tags:
        - control
      summary: Create Scan
      operationId: create_scan_api_v1_scans_post
      parameters:
        - in: header
          name: Idempotency-Key
          required: false
          schema:
            anyOf:
              - maxLength: 200
                minLength: 8
                type: string
              - type: 'null'
            title: Idempotency-Key
        - in: header
          name: X-Correlation-ID
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Correlation-Id
        - in: header
          name: authorization
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RepositoryScanCreate'
        required: true
      responses:
        '202':
          content:
            application/json:
              schema:
                additionalProperties: true
                title: Response Create Scan Api V1 Scans Post
                type: object
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
      security:
        - BearerAuth: []
components:
  schemas:
    RepositoryScanCreate:
      properties:
        client_request_id:
          anyOf:
            - maxLength: 200
              minLength: 8
              type: string
            - type: 'null'
          title: Client Request Id
        config:
          additionalProperties: true
          title: Config
          type: object
        repository_id:
          title: Repository Id
          type: string
        scan_type:
          default: security
          pattern: ^(security|onboarding|full)$
          title: Scan Type
          type: string
        source_ref:
          anyOf:
            - maxLength: 256
              type: string
            - type: 'null'
          title: Source Ref
        trigger_type:
          default: manual
          pattern: ^(manual|onboarding|scheduled|deployment|api)$
          title: Trigger Type
          type: string
        workspace_id:
          title: Workspace Id
          type: string
      required:
        - workspace_id
        - repository_id
      title: RepositoryScanCreate
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ValidationError:
      properties:
        ctx:
          title: Context
          type: object
        input:
          title: Input
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    BearerAuth:
      bearerFormat: JWT
      scheme: bearer
      type: http

````