> ## Documentation Index
> Fetch the complete documentation index at: https://altostrat.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Latest Scan Status

> Retrieves the status of the most recent scan associated with a specific schedule, whether it is running, completed, or failed.



## OpenAPI

````yaml /api/en/cve-scans.yaml get /scans/cve/{scanScheduleId}/status
openapi: 3.0.3
info:
  title: Altostrat CVE Scans API
  version: 1.0.0
  description: >-
    The Altostrat CVE Scans API is the microservice responsible for scheduling,
    executing, and reporting on network vulnerability scans.


    It is a core component of the Altostrat SDX platform's security posture
    management, providing deep insights into potential vulnerabilities across
    MikroTik networks to complement the platform's automation and AI
    capabilities.


    This API allows you to programmatically manage:

    - **Scan Schedules:** Define recurring vulnerability scans for specific
    network sites, including frequency, timing, and vulnerability thresholds.

    - **Scan Results:** Access detailed historical and in-progress scan reports,
    including discovered CVEs, affected hosts, and severity scores.

    - **Vulnerability Management:** Query specific CVEs by device (MAC address)
    and manage their lifecycle by marking them as accepted or mitigated.


    Developers use this API to integrate automated vulnerability scanning and
    reporting into their network management workflows and security dashboards.
servers:
  - url: https://v1.api.altostrat.io
    description: Altostrat Production API Server
security:
  - bearerAuth: []
tags:
  - name: Scan Schedules
    description: Manage the configuration and scheduling of recurring vulnerability scans.
  - name: Scan Execution
    description: Manually trigger and terminate scan jobs.
  - name: Scan Results
    description: Retrieve historical and in-progress scan reports and data.
  - name: Vulnerability Intelligence
    description: Query for specific vulnerability data and mitigation advice.
  - name: Vulnerability Management
    description: Manage the lifecycle and status of discovered vulnerabilities.
paths:
  /scans/cve/{scanScheduleId}/status:
    get:
      tags:
        - Scan Results
      summary: Get Latest Scan Status
      description: >-
        Retrieves the status of the most recent scan associated with a specific
        schedule, whether it is running, completed, or failed.
      operationId: getScanStatus
      parameters:
        - name: scanScheduleId
          in: path
          required: true
          description: The unique identifier of the scan schedule.
          schema:
            type: string
            format: uuid
            example: 9c43cc95-f313-49a3-b632-524f7a24503b
      responses:
        '200':
          description: The status of the latest scan for the schedule.
          content:
            application/json:
              schema:
                type: object
                properties:
                  targets:
                    type: array
                    description: A list of site IDs that were targeted in the scan.
                    items:
                      type: string
                      format: uuid
                    example:
                      - 9c3c1392-7f36-4240-85f2-273573c0384a
                  scanned:
                    type: array
                    description: >-
                      A list of site IDs that have completed scanning
                      (successfully or with failures).
                    items:
                      type: string
                      format: uuid
                    example:
                      - 9c3c1392-7f36-4240-85f2-273573c0384a
                  failed:
                    type: array
                    description: A list of site IDs where the scan failed to complete.
                    items:
                      type: string
                      format: uuid
                    example: []
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
components:
  responses:
    UnauthorizedError:
      description: >-
        Unauthorized - The request requires authentication, but none was
        provided or it was invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    NotFoundError:
      description: Not Found - The requested resource could not be found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  schemas:
    ErrorResponse:
      type: object
      properties:
        type:
          type: string
          description: A broad category for the error (e.g., 'invalid_request_error').
          example: invalid_request_error
        code:
          type: string
          description: A short, unique string identifying the specific error.
          example: parameter_missing
        message:
          type: string
          description: A human-readable description of what went wrong.
          example: The 'description' parameter is required for this request.
        doc_url:
          type: string
          description: >-
            A direct link to the documentation page for this specific error
            code.
          example: https://docs.altostrat.io/errors/parameter_missing
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: 'Enter your bearer token in the format: Bearer {token}'

````