Bug 101 - Type name should not appear in return body JSON content
Summary: Type name should not appear in return body JSON content
Status: IN_PROGRESS
Alias: None
Product: MEC
Classification: Unclassified
Component: GS 011 (show other bugs)
Version: Release 1
Hardware: PC Windows
Assignee: walter FEATHERSTONE
 
Reported: 2019-01-13 19:12 CET by walter FEATHERSTONE
Modified: 2019-01-13 19:26 CET (History)
2 users (show)

See Also:
Version number of the related document: V1.1.1
OpenAPI issue category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description walter FEATHERSTONE 2019-01-13 19:12:14 CET
Example, where the ServiceInfo shouldn’t appear in the response
          schema:
            type: array
            items:
              type: object
              properties:
                ServiceInfo:
                  $ref: '#/definitions/ServiceInfo'

Should simply be:
          schema:
            type: array
            items:
              $ref: '#/definitions/ServiceInfo'

And
          schema:
            type: object
            properties:
              ServiceInfo:
                $ref: '#/definitions/ServiceInfo'

Should simply be:
          schema:
            $ref: '#/definitions/ServiceInfo'
Comment 1 walter FEATHERSTONE 2019-01-13 19:26:29 CET
It's proposed to defer this until the OpenAPI 3.0 descriptions are available, since OpenAPI 2.0 only allows a single return schema. Therefore there's no apparent way to indicate that the return type is optional which is a problem when the return type has a cardinality of 0 to 1 or N, e.g. with respect to ProblemDetails, or even ServiceInfo.