VNFLifecycleManagement.yaml 98.8 KB
Newer Older
      - name: cancelMode
        description: >
          The POST request to this resource shall include a CancelMode
          structure in the payload body to choose between "graceful" and
          "forceful" cancellation.
        in: body
        required: true
        schema:
          $ref: "../../definitions/SOL002SOL003VNFLifecycleManagement_def.yaml#/definitions/CancelMode"
      description: >
        The POST method initiates cancelling an ongoing VNF lifecycle
        operation while it is being executed or rolled back, i.e. the related
        "Individual VNF LCM operation occurrence" is either in "PROCESSING" or
            The request has been accepted for processing, but processing has not 
            been completed.
            The response shall have an empty payload body.
            #TODO: Add headers defined in 4.3.4.3
            WWW-Authenticate:
              description: >
                Challenge if the corresponding HTTP request has not provided
                authorization, or error details if the corresponding HTTP
                request has provided an invalid authorization token.
              type: string
              maximum: 1
              minimum: 0
            Version:
              description: The used API version.
              type: string
              maximum: 1
              minimum: 1
        400:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/400"
        401:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/401"
        403:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/403"
        404:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/404"
        405:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/405"
        406:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/406"
        409:
          # description: >
          #   409 CONFLICT

          #   Error: The operation cannot be executed currently, due to a conflict with the state of
          #   the VNF LCM operation occurrence resource.
          #   Typically, this is due to the fact that the operation occurrence is not in STARTING,
          #   PROCESSING or ROLLING_BACK state.
          #   The response body shall contain a ProblemDetails structure, in which the "detail" attribute shall
          #   convey more information about the error.
          # schema:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/409"
        416:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/416"
        422:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/422"
        429:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/429"
        500:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/500"
        503:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/503"
        504:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/504"
  ###############################################################################
  # Subscriptions                                                               #
  ###############################################################################
Sana Zulfiqar's avatar
Sana Zulfiqar committed
    #SOL002 location: 5.4.18
    parameters:
      - name: Version
        description: >
          Version of the API requested to use when responding to this request.
        in: header
        required: true
        type: string
      - name: Authorization
        description: >
          The authorization token for the request.
          Reference: IETF RFC 7235
        in: header
        required: false
        type: string
      description: >
        The POST method creates a new subscription.
      parameters:
        - name: LccnSubscriptionRequest
          description: >
Sana Zulfiqar's avatar
Sana Zulfiqar committed
            Details of the subscription to be created, as defined in clause 5.5.2.15.
          in: body
          required: true
          schema:
            $ref: "../../definitions/SOL002SOL003VNFLifecycleManagement_def.yaml#/definitions/LccnSubscriptionRequest"
      responses:
        201:
          description: >
            The subscription has been created successfully. The response body shall
            contain a representation of the created "Individual subscription" resource.
            The HTTP response shall include a "Location" HTTP header that
            points to the created "Individual subscription" resource.
          headers:
            Content-Type:
              description: The MIME type of the body of the response.
              type: string
              maximum: 1
              minimum: 1
            Location:
              description: The resource URI of the created VNF instance
              type: string
              format: url
            WWW-Authenticate:
              description: >
                Challenge if the corresponding HTTP request has not provided
                authorization, or error details if the corresponding HTTP
                request has provided an invalid authorization token.
              type: string
              maximum: 1
              minimum: 0
            Version:
              description: The used API version.
              type: string
              maximum: 1
              minimum: 1
          schema:
            $ref: "../../definitions/SOL002SOL003VNFLifecycleManagement_def.yaml#/definitions/LccnSubscription"
          # description: >
          #   303 SEE OTHER

          #   A subscription with the same callbackURI and the same filter already exists and the policy of the VNFM
          #   is to not create redundant subscriptions.
          #   The HTTP response shall include a "Location" HTTP header that contains the resource URI of the existing
          #   subscription resource.
          #   The response body shall be empty.
          # schema:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/303"
        400:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/400"
        401:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/401"
        403:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/403"
        404:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/404"
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/405"
        406:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/406"
        416:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/416"
        422:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/422"
        429:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/429"
        500:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/500"
        503:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/503"
        504:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/504"
      description: >
        The GET method queries the list of active subscriptions of the
        functional block that invokes the method. It can be used e.g. for
        resynchronization after error situations.
      parameters:
        - name: filter
          description: >
            Attribute-based filtering expression according to clause 5.2 of ETSI GS NFV-SOL 013.
            The VNFM shall support receiving this parameter as part of the URI query string.
            The EM may supply this parameter. All attribute names that appear in the LccnSubscription
            and in data types referenced from it shall be supported by the VNFM in the filter expression.

            EXAMPLE
            objects
            obj1: {"id":123, "weight":100, "parts":[{"id":1, "color":"red"}, {"id":2, "color":"green"}]}
            obj2: {"id":456, "weight":500, "parts":[{"id":3, "color":"green"}, {"id":4, "color":"blue"}]}

            Request 1:
            GET …/container

            Response 1:
            [
                {"id":123, "weight":100, "parts":[{"id":1, "color":"red"}, {"id":2, "color":"green"}]},
                {"id":456, "weight":500, "parts":[{"id":3, "color":"green"}, {"id":4, "color":"blue"}]}
            ]

            Request 2:
            GET …/container?filter=(eq.weight,100)

            Response 2:
            [
                {"id":123, "weight":100, "parts":[{"id":1, "color":"red"}, {"id":2, "color":"green"}]}
            ]
          #Request 2 in EXAMPLE from clause 4.3.2 probably wrong, since "," should be used after opOne (eq), "." is used
          in: query
          required: false
          type: string
        - name: nextpage_opaque_marker
          description: >
            Marker to obtain the next page of a paged response.
            Shall be supported by the VNFM if the VNFM supports
            alternative 2 (paging) according to clause 5.4.2.1
            of ETSI GS NFV-SOL 013 for this resource.
          in: query
          required: false
          type: string
          description: >
            The list of subscriptions has been queried successfully.
            The response body shall contain in an array the representations of all active subscriptions
            of the functional block that invokes the method, i.e. zero or more representations of lifecycle
            change notification subscriptions as defined in clause 5.5.2.16.
          headers:
            Content-Type:
              description: The MIME type of the body of the response.
              type: string
              maximum: 1
              minimum: 1
            WWW-Authenticate:
              description: >
                Challenge if the corresponding HTTP request has not provided
                authorization, or error details if the corresponding HTTP
                request has provided an invalid authorization token.
              type: string
              maximum: 1
              minimum: 0
            Version:
              description: The used API version.
              type: string
              maximum: 1
              minimum: 1
          schema:
            $ref: "../../definitions/SOL002SOL003VNFLifecycleManagement_def.yaml#/definitions/LccnSubscription"
        400:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/400"
        401:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/401"
        403:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/403"
        404:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/404"
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/405"
        406:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/406"
        416:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/416"
        422:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/422"
        429:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/429"
        500:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/500"
        503:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/503"
        504:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/504"
  ###############################################################################
  # Individual subscription                                                     #
  ###############################################################################
Sana Zulfiqar's avatar
Sana Zulfiqar committed
    #SOL002 location: 5.4.19
          Identifier of this subscription.
          This identifier can be retrieved from the resource referenced by
          the "Location" HTTP header in the response to a POST request
          creating a new subscription resource. It can also be retrieved from
          the "id" attribute in the payload body of that response.
        in: path
        type: string
        required: true
      - name: Version
        description: >
          Version of the API requested to use when responding to this request.
        in: header
        required: true
        type: string
      - name: Authorization
        description: >
          The authorization token for the request.
          Reference: IETF RFC 7235
        in: header
        required: false
        type: string
    get:
      description: >
        The GET method retrieves information about a subscription by reading
          description: >
            The operation has completed successfully.
            The response body shall contain a representation of the
          headers:
            Content-Type:
              description: The MIME type of the body of the response.
              type: string
              maximum: 1
              minimum: 1
            WWW-Authenticate:
              description: >
                Challenge if the corresponding HTTP request has not provided
                authorization, or error details if the corresponding HTTP
                request has provided an invalid authorization token.
              type: string
              maximum: 1
              minimum: 0
            Version:
              description: The used API version.
              type: string
              maximum: 1
              minimum: 1
          schema:
            $ref: "../../definitions/SOL002SOL003VNFLifecycleManagement_def.yaml#/definitions/LccnSubscription"
        400:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/400"
        401:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/401"
        403:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/403"
        404:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/404"
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/405"
        406:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/406"
        416:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/416"
        422:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/422"
        429:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/429"
        500:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/500"
        503:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/503"
        504:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/504"
    delete:
      description: >
        The DELETE method terminates an individual subscription.
      responses:
        204:
          description: >
            The "Individual subscription" resource has been deleted successfully.
            The response body shall be empty.
          headers:
            WWW-Authenticate:
              description: >
                Challenge if the corresponding HTTP request has not provided
                authorization, or error details if the corresponding HTTP
                request has provided an invalid authorization token.
              type: string
              maximum: 1
              minimum: 0
            Version:
              description: The used API version.
              type: string
              maximum: 1
              minimum: 1
        400:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/400"
        401:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/401"
        403:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/403"
        404:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/404"
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/405"
        406:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/406"
        416:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/416"
        422:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/422"
        429:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/429"
        500:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/500"
        503:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/503"
        504:
          $ref: "../../responses/SOL002SOL003_resp.yaml#/responses/504"