0

I have a URL with an object parameter;

https://myurl.com?myobj[anyvalue][limitedvalue]=anyothervalue

Where anyvalue and anyothervalue can be any string. The string values in limitedvalue are limited and known in advance.

How can I represent this in OpenAPI?

For example, I can represent a basic object with known properties;

https://myurl.com?myobj[limitedvalue]=anyothervalue

as;

- name: myobj
  in: query
  required: true
  schema:
    type: object
    properties:
      limitedValueOne:
        type: "string"
      limitedValueTwo:
        type: "string"
myol
  • 7,355
  • 18
  • 75
  • 124
  • 1
    As of OAS 3.1, nested objects and arrays of objects are **not supported** in query strings. See the linked Q&As for details. – Helen Aug 18 '21 at 11:34

0 Answers0