paths:
  get:
    tags:
    - port
    summary: "Export entities from a namespace"
    parameters:
    - $ref: "#/components/parameters/namespace"
    responses:
      200:
        $ref: "#/components/schemas/port"

  post:
    tags:
    - port
    summary: "Import entities into a namespace"
    parameters:
    - $ref: "#/components/parameters/namespace"
    requestBody:
      $ref: "#/components/schemas/port"
    responses:
      200:
        content:
          application/json:
            schema:
              type: object
              properties:
                namespace:
                  type: int
                  example: "5"

components:
  parameters:
    namespace:
      $ref: "./swagger.yaml#/components/parameters/namespace"

  schemas:
    one:
      $ref: "./swagger.yaml#/components/schemas/one"

    port:
      description: "A {namespace:[entity]} json object"
      content:
        application/json:
          schema:
            type: object
            properties:
              namespace:
                type: array
                items:
                  $ref: "#/components/schemas/one"
