openapi: "3.0.0"

info:
  title: Process Assurance Runtime API
  description: Test
  version: 0.0.1
servers:
  - url: http://localhost:8085/api


# Paths supported by the server application
paths:
  /getConnections/:
    get:
      operationId: qa_runtime.po_manager.getConnections
      summary: returns currently connected po-runtimes
      description: returns po-runtimes
      responses:
        200:
          description: OK
          content:
            application/json:
              schema:
                type: object
                example: {"localhost:8083"}
                properties:
                    optimum_parameters:
                        type: array
                        description: returns uri of all connected po-runtimes
        400:
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                example: {message: "URI not valid"}
                properties:
                    message:
                        type: string
                        description: Contains the message that clarifies the error                   
  /addConnection/{uri}:
    get:
      operationId: qa_runtime.po_manager.createConnection
      summary: adds po-runtime 
      description: adds po-runtime
      parameters:
        - in: path 
          name: uri
          schema:
            type: string
            example: "localhost:8082"
          allowReserved: true
          required: true
          description: URI of the PO-Runtime to be added
      responses:
        200:
          description: OK
          content:
            application/json:
              schema:
                type: object
                example: {"localhost:8083"}
                properties:
                    optimum_parameters:
                        type: array
                        description: returns uri of all connected po-runtimes
        400:
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                example: {message: "URI not valid"}
                properties:
                    message:
                        type: string
                        description: Contains the message that clarifies the error                   
  /deleteConnection/{idx}:
    get:
      operationId: qa_runtime.po_manager.closeConnection
      summary: removes po-runtime 
      description: removes po-runtime
      parameters:
        - in: path 
          name: idx 
          schema:
            type: integer 
            example: 1
          required: true
          description: ID of the po-runtime to be removed
      responses:
        200:
          description: OK
          content:
            application/json:
              schema:
                type: object
                example: {"localhost:8083"}
                properties:
                    optimum_parameters:
                        type: array
                        description: returns uri of all connected po-runtimes
        400:
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                example: {message: "ID not valid"}
                properties:
                    message:
                        type: string
                        description: Contains the message that clarifies the error                   
