Added apis for Feature 10339 - Enhanced Alarm Mgmt. (SOL005 FM Interface)
[osm/SOL005.git] / osm-openapi.yaml
index 4478965..aaee616 100644 (file)
@@ -1407,6 +1407,12 @@ paths:
         description: NS Instance ID
         schema:
           type: string
+      - name: vcaStatusRefresh
+        in: query
+        required: false
+        description: Set to true if vca status needs to be refreshed.
+        schema:
+          type: boolean
     get:
       tags:
         - "NS instances"
@@ -2255,6 +2261,133 @@ paths:
           $ref: '#/components/responses/UnexpectedError'
 # END NS Instances
 
+# BEGIN Alarms
+  '/nsfm/v1/alarms':
+    get:
+      tags:
+        - "Alarms"
+      summary: Query information about multiple alarms
+      description: Query information about multiple alarms
+      operationId: getAlarms
+      responses:
+        '200':
+          description: OK
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ArrayOfAlarm'
+            application/yaml:
+              schema:
+                $ref: '#/components/schemas/ArrayOfAlarm'
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+  '/nsfm/v1/alarms/{uuid}':
+    parameters:
+      - name: uuid
+        in: path
+        required: true
+        description: Alarm UUID
+        schema:
+          type: string
+    get:
+      tags:
+        - "Alarms"
+      summary: Read an individual Alarm
+      description: Read an individual Alarm
+      operationId: getAlarm
+      responses:
+        '200':
+          description: OK
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/Alarm'
+            application/yaml:
+              schema:
+                $ref: '#/components/schemas/Alarm'
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+    patch:
+      tags:
+        - "Alarms"
+      summary: Modify the data of an  individual Alarm
+      description: Modify the data of an  individual Alarm
+      operationId: updateAlarm
+      requestBody:
+        $ref: '#/components/requestBodies/AlarmInfoModifications'
+      responses:
+        '204':
+          description: No Content
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+# END Alarms
+
 # BEGIN NetSlice Templates
   '/nst/v1/netslice_templates':
     get:
@@ -5654,6 +5787,218 @@ paths:
           $ref: '#/components/responses/UnexpectedError'
         default:
           $ref: '#/components/responses/UnexpectedError'
+  '/admin/v1/vca':
+    get:
+      tags:
+        - "Infrastructure"
+        - "Admin"
+      summary: Query information about multiple VCAs
+      description: Query information about multiple VCAs
+      operationId: getVcas
+      responses:
+        '200':
+          description: OK
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ArrayOfVcaInfo'
+            application/yaml:
+              schema:
+                $ref: '#/components/schemas/ArrayOfVcaInfo'
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+    post:
+      tags:
+        - "Infrastructure"
+        - "Admin"
+      summary: Create a new VCA
+      description: Create a new VCA
+      operationId: createVca
+      requestBody:
+        $ref: '#/components/requestBodies/CreateVcaRequest'
+      responses:
+        '202':
+          description: Accepted
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ObjectId_plus_OpId'
+            application/yaml:
+              schema:
+                $ref: '#/components/schemas/ObjectId_plus_OpId'
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+  '/admin/v1/vca/{vcaId}':
+    parameters:
+      - name: vcaId
+        in: path
+        required: true
+        description: VCA ID
+        schema:
+          type: string
+          format: uuid
+    get:
+      tags:
+        - "Infrastructure"
+        - "Admin"
+      summary: Query information about an individual VCA
+      description: Query information about an individual VCA
+      operationId: getVca
+      responses:
+        '200':
+          description: OK
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/VcaInfo'
+            application/yaml:
+              schema:
+                $ref: '#/components/schemas/VcaInfo'
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+    patch:
+      tags:
+        - "Infrastructure"
+        - "Admin"
+      summary: Modify a VCA
+      description: Modify a VCA
+      operationId: editVca
+      requestBody:
+        $ref: '#/components/requestBodies/EditVcaRequest'
+      responses:
+        '202':
+          description: Accepted
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/OpId'
+            application/yaml:
+              schema:
+                $ref: '#/components/schemas/OpId'
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
+    delete:
+      tags:
+        - "Infrastructure"
+        - "Admin"
+      summary: Delete a VCA
+      description: Delete a VCA
+      operationId: deleteVca
+      responses:
+        '202':
+          description: Accepted
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
   '/admin/v1/k8srepos':
     get:
       tags:
@@ -5982,6 +6327,20 @@ components:
         description:
           description: NSD Description
           type: string
+    AlarmInfoModifications:
+      description: |
+        Alarm Information
+      type: object
+      properties:
+        id:
+          description: UUID
+          type: string
+        is_enable:
+          description: To enable/disable the alarm.
+          type: string
+        threshold:
+          description: Threshold value of the Alarm
+          type: string
     NsdInfo:
       description: |
         NS Descriptor Information
@@ -6706,6 +7065,45 @@ components:
       type: array
       items:
         $ref: '#/components/schemas/NetSliceInstance'
+    Alarm:
+      description: |
+        Alarm Information
+      type: object
+      properties:
+        _id:
+          description: Identifier of the Alarm.
+          type: string
+          format: uuid
+        id:
+          description: Identifier of the Alarm.
+          type: string
+          format: uuid
+        metric:
+          description: Alarm metric.
+          type: string
+        threshold:
+          description: Threshold value of the Alarm.
+          type: number
+          format: float
+        operation:
+          description: Operation to be applied.
+          type: string
+        action:
+          description: Action to be taken.
+          type: string
+        status:
+          description: Current status of the alarm.
+          type: string
+      required:
+        - _id
+        - id
+        - metric
+        - threshold
+        - operation
+    ArrayOfAlarm:
+      type: array
+      items:
+        $ref: '#/components/schemas/Alarm'
     # CreateNsiRequest:
       # Substituted by InstantiateNsiRequest
     InstantiateNsiRequest:
@@ -7311,6 +7709,10 @@ components:
           type: integer
           minimum: 0
           nullable: false
+        vca:
+          type: integer
+          minimum: 0
+          nullable: false
         k8srepos:
           type: integer
           minimum: 0
@@ -7363,6 +7765,10 @@ components:
           type: integer
           minimum: 0
           nullable: true
+        vca:
+          type: integer
+          minimum: 0
+          nullable: true
         k8srepos:
           type: integer
           minimum: 0
@@ -7496,9 +7902,14 @@ components:
           type: string
         vim_password:
           type: string
+        vca:
+          type: string
+          format: uuid
         config:
           type: object
           additionalProperties: true
+        resources:
+          type: object
     ArrayOfVimInfo:
       type: array
       items:
@@ -7530,9 +7941,14 @@ components:
           type: string
         vim_password:
           type: string
+        vca:
+          type: string
+          format: uuid
         config:
           type: object
           additionalProperties: true
+        resources:
+          type: object
       required:
         - name
         - vim_url
@@ -7563,6 +7979,9 @@ components:
           type: string
         vim_password:
           type: string
+        vca:
+          type: string
+          format: uuid
         config:
           type: object
           additionalProperties: true
@@ -7965,6 +8384,113 @@ components:
           items:
             type: string
       additionalProperties: false
+    VcaInfo:
+      type: object
+      properties:
+        _id:
+          type: string
+          format: uuid
+        schema_version:
+          type: string
+          format: X.Y[.Z]
+        schema_type:
+          type: string
+        name:
+          type: string
+        description:
+          type: string
+        endpoints:
+          type: string
+        user:
+          type: string
+        secret:
+          type: string
+        cacert:
+          type: string
+        lxd-cloud:
+          type: string
+        lxd-credentials:
+          type: string
+        k8s-cloud:
+          type: string
+        k8s-credentials:
+          type: string
+        model-config:
+          type: object
+          additionalProperties: true
+    ArrayOfVcaInfo:
+      type: array
+      items:
+        $ref: '#/components/schemas/VcaInfo'
+    CreateVcaRequest:
+      type: object
+      properties:
+        schema_version:
+          type: string
+          format: X.Y[.Z]
+        schema_type:
+          type: string
+        name:
+          type: string
+        description:
+          type: string
+        endpoints:
+          type: string
+        user:
+          type: string
+        secret:
+          type: string
+        cacert:
+          type: string
+        lxd-cloud:
+          type: string
+        lxd-credentials:
+          type: string
+        k8s-cloud:
+          type: string
+        k8s-credentials:
+          type: string
+        model-config:
+          type: object
+          additionalProperties: true
+      required:
+        - name
+        - endpoints
+        - user
+        - secret
+        - cacert
+        - lxd-cloud
+        - lxd-credentials
+        - k8s-cloud
+        - k8s-credentials
+      additionalProperties: false
+    EditVcaRequest:
+      type: object
+      properties:
+        name:
+          type: string
+        description:
+          type: string
+        endpoints:
+          type: string
+        user:
+          type: string
+        secret:
+          type: string
+        cacert:
+          type: string
+        lxd-cloud:
+          type: string
+        lxd-credentials:
+          type: string
+        k8s-cloud:
+          type: string
+        k8s-credentials:
+          type: string
+        model-config:
+          type: object
+          additionalProperties: true
+      additionalProperties: false
     K8sRepoType:
       type: string
       enum:
@@ -7985,6 +8511,24 @@ components:
         url:
           type: string
           format: uri
+        username:
+          type: string
+          description: repository username
+        password:
+          type: string
+          description: repository password
+        ca-file:
+          type: string
+          description: verify certificates of HTTPS-enabled servers using this CA bundle
+        cert-file:
+          type: string
+          description: identify HTTPS client using this SSL certificate file
+        skip-tls-verify:
+          type: boolean
+          description: skip tls certificate checks for the repository
+        key-file:
+          type: string
+          description: identify HTTPS client using this SSL key file
     ArrayOfK8sRepoInfo:
       type: array
       items:
@@ -8191,6 +8735,14 @@ components:
         application/yaml:
           schema:
             $ref: '#/components/schemas/NsdInfoModifications'
+    AlarmInfoModifications:
+      content:
+        application/json:
+          schema:
+            $ref: '#/components/schemas/AlarmInfoModifications'
+        application/yaml:
+          schema:
+            $ref: '#/components/schemas/AlarmInfoModifications'
     NsDescriptor:
       content:
         text/plain:
@@ -8445,6 +8997,22 @@ components:
         application/yaml:
           schema:
             $ref: '#/components/schemas/EditK8sClusterRequest'
+    CreateVcaRequest:
+      content:
+        application/json:
+          schema:
+            $ref: '#/components/schemas/CreateVcaRequest'
+        application/yaml:
+          schema:
+            $ref: '#/components/schemas/CreateVcaRequest'
+    EditVcaRequest:
+      content:
+        application/json:
+          schema:
+            $ref: '#/components/schemas/EditVcaRequest'
+        application/yaml:
+          schema:
+            $ref: '#/components/schemas/EditVcaRequest'
     CreateK8sRepoRequest:
       content:
         application/json: