Hello! When using reitit + malli (coercion) + Swagger integration, is there a way to tell Swagger what is the type of a certain schema attribute? I used to have models with optional attributes defined like [:map [:attribute {:optional true} string?]]
and that showed as expected on the Swagger ui (i.e. attribute
is not required and has type string). But I had to change the attribute definition to [:map [:attribute [:or nil? string?]]]
and now the attribute type is not showed as string anymore on Swagger ui. Is there a way to say what type should appear on the ui, something like [:map [:attribute {:type string} [:or nil? string?]]]
?
Any properties from schema options with json-schema
namespaces are lifted to the resulting json-schema, and override the automatic properties.
@juhoteperi What is the practical difference between oneOf
and anyOf
?
https://json-schema.org/understanding-json-schema/reference/combining.html
In this case, probably nothing