molten
molten copied to clipboard
openapi: support required fields read/writeOnly
The OpenAPI spec 3.0.0 specifies the following for read/writeOnly schema properties :
readOnly: If the property is marked as readOnly being true and is in
the required list, the required will take effect on the response
only.
This justifies adding a required argument on Field. Indeed this may
be useful to API clients to know that the field will always be present
in the response even if in python its type is Optional due to reuse of
the schema for request and response.
Thanks! I'll try to take a look at this next week.
is this actually different than the responseOnly flag?