cancel
Showing results for 
Search instead for 
Did you mean: 

Issue with JSON content in query parameter

Occasional Visitor

Issue with JSON content in query parameter

Hi,

refer this yaml 

- name: home-plmn-id
  in: query
  description: PLMN ID of the HPLMN
  content:
      application/json:
        schema:
          type: object
          properties:
            mcc:
              $ref: '#/components/schemas/Mcc'
            mnc:
              $ref: '#/components/schemas/Mnc'
          required:
            - mcc

Does swagger supports "JSON object in query parameter" ?

 

when i open this schema in swagger UI , it doesnt render JSON query parameters. (😱 Could not render this component, see the console.)

 

when i try to generate server stub using codegen , it reports error that schema is not valid but on UI it is already validated. 

2 REPLIES 2
Moderator

Re: Issue with JSON content in query parameter

At the moment, we do not support 'content' under query parameters.

Moderator

Re: Issue with JSON content in query parameter


@santoshJD wrote:

 

when i open this schema in swagger UI , it doesnt render JSON query parameters. (😱 Could not render this component, see the console.)


This UI issue is tracked on GitHub here:
https://github.com/swagger-api/swagger-ui/issues/4442


Helen Kosova
SmartBear Technical Writer
________________________
Vote up helpful replies.
Accept this reply if you think it's the best solution to your question.
New Here?
Join us and watch the welcome video:
Top Kudoed Authors