Uh oh!
There was an error while loading. Please reload this page.
added schema for all parameters - #654
Conversation
This addresses #412, #437, #69, #401, #179 (by inclusion of the For issue #222, we can also add a format for For issue #300, since schemas can be reused, this should address that as well. This solves #595 if we can define the serialization strategy |
| <a name="parameterUniqueItems"></a>uniqueItems | `boolean` | See http://json-schema.org/latest/json-schema-validation.html#anchor49. | ||
| <a name="parameterEnum"></a>enum | [*] | See http://json-schema.org/latest/json-schema-validation.html#anchor76. | ||
| <a name="parameterMultipleOf"></a>multipleOf | `number` | See http://json-schema.org/latest/json-schema-validation.html#anchor14. | ||
| <a name="parameterSchema"></a>schema | [Schema Object](#schemaObject) | The schema defining the type used for the parameter. |
There was a problem hiding this comment.
Allow a reference object (i.e. a reference to a schema object) here too?
There was a problem hiding this comment.
@ePaul - The Schema Object allows a $ref as its value, so there's no need to be explicit about it. It's the same as how body parameters behave today.
fehguy
commented
Apr 15, 2016
need to reconsider this when looking at 6570 support |
fehguy
commented
Apr 15, 2016
@OAI/tdc please post other comments here--i will not merge until a serialization strategy is provided and there is more time for feedback |
webron
commented
Apr 19, 2016
This does not solve #69 nor #401. To me the serialization strategy can be controlled by a To me, the main issue is arrays and the existing I do not advocate using complex models for query/path/header parameters (body and form are okay) - but in favor of simplicity I 👍 the concept. Just need to work through the open questions. |
fehguy
commented
Apr 20, 2016
|
Vanuan
commented
Apr 21, 2016
Is there any rough implementation? I'm looking for a simple query parameter of type object serialized into a JSON string. |
ePaul
commented
Apr 21, 2016
@Vanuan I'm not aware of any. We are currently working on the next version of the specification (3.0), and only if that it out, the tools can reliably be updated to support it. (I guess some tools will start implementation earlier, though.) |
Is there some criteria or time frame for 3.0 to be released?
Or you could say that you target supporting specific features, like an ability to specify fields like this: Is GitHub issues is the only place or is there some highlevel roadmap with milestone? |
webron
commented
Apr 22, 2016
@Vanuan we're aiming for a summer release for 3.0. The changes are done via specific feature requests and not aiming to support specific APIs. Github issues is the place. It means that not all APIs could be described with OpenAPI. Whether applications change their APIs or don't use OpenAPI is their call. |
This is NOT a complete change, but conceptually it loosens the requirement that all parameters except
bodyparameters be of a simple type. Instead, a schema can be provided for all parameter types.For parameter types of type
body, the schema will be serialized by theconsumesattribute. For all other parameter types, a serialization strategy needs to be defined (and is still TBD for definition).This serialization strategy would be responsible for turning a complex object into JSON, for example.