openapi: 3.0.2
info:
  title: NDT Inspection - EXTERNAL_IMAGE
  description: NDT Inspection - EXTERNAL_IMAGE
  version: 1.0.0
paths:
  /process:
    post:
      tags:
        - Process
      summary: Run Process
      description: |-
        This functions runs a process on a Module's Function
        on some Input Parameters.
        It returns the processed Output Parameters.

        Args:
            process_request (ProcessRequest): The Process Request object containing the Input Parameters

        Returns:
            ProcessResponse: The Process Response object containing the Output Parameters
      operationId: run_process_modules_process_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProcessRequest'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProcessResponse'
  /:
    get:
      summary: Root
      operationId: root__get
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
components:
  schemas:
    FunctionIdentity:
      title: FunctionIdentity
      required:
        - function_id
      type: object
      properties:
        function_id:
          title: Function Id
          maxLength: 100
          minLength: 3
          pattern: '^[a-zA-Z0-9]+(-[a-zA-Z0-9]+)*$'
          type: string
    ModuleIdentity:
      title: ModuleIdentity
      required:
        - module_id
        - module_version
      type: object
      properties:
        module_id:
          title: Module Id
          maxLength: 100
          minLength: 5
          pattern: '^[a-zA-Z]+(-[a-zA-Z]+)*$'
          type: string
        module_version:
          title: Module Version
          type: string
    Parameter:
      title: Parameter
      required:
        - name
        - type
      type: object
      properties:
        name:
          title: Name
          maxLength: 100
          minLength: 1
          pattern: '^[a-zA-Z0-9]'
          type: string
        documentation:
          title: Documentation
          maxLength: 1000
          minLength: 0
          type: string
          default: ''
        type:
          $ref: '#/components/schemas/ParameterType'
        value:
          title: Value
        param_unique_id:
          title: Param Unique Id
          type: string
        min:
          title: Min
          type: number
        max:
          title: Max
          type: number
        step:
          title: Step
          type: number
        file_type:
          $ref: '#/components/schemas/ParameterFileType'
    ParameterFileType:
      title: ParameterFileType
      enum:
        - RAW_B64
        - FILESYSTEM_STORAGE
        - INTERNAL_SHARED_FILESYSTEM
      type: string
      description: An enumeration.
    ParameterType:
      title: ParameterType
      enum:
        - ALL
        - NONE
        - NUMBER
        - LIST_NUMBERS
        - STRING
        - LIST_STRINGS
        - BOOLEAN
        - IMAGE
        - LIST_IMAGES
        - FILE
        - LIST_FILES
        - OBJECT
      type: string
      description: An enumeration.
    ProcessRequest:
      title: ProcessRequest
      required:
        - module_identity
        - function_identity
        - input_params
        - output_params
        - instance_id
      type: object
      properties:
        module_identity:
          $ref: '#/components/schemas/ModuleIdentity'
        function_identity:
          $ref: '#/components/schemas/FunctionIdentity'
        input_params:
          title: Input Params
          type: array
          items:
            $ref: '#/components/schemas/Parameter'
        output_params:
          title: Output Params
          type: array
          items:
            $ref: '#/components/schemas/Parameter'
        instance_id:
          title: Instance ID
          type: string
    ProcessResponse:
      title: ProcessResponse
      required:
        - output_params
        - process_response_time
      type: object
      properties:
        output_params:
          title: Output Params
          type: array
          items:
            $ref: '#/components/schemas/Parameter'
        instance_id:
          title: Instance ID
          type: string