Hello,
Wanted to report that as of version 3.21.2 the library is not working correctly with readOnly fields marked as required when using the automatic validation of requests from CastAndValidate Plug. It returns 422 error on requests missing the readOnly field, while it should allow them and only require this field when returning responses.
By looking at the code, I think that it's safe to assume that all the functions in the operation2.ex file should operate as :write scope, since they handle requests only.
This issue effectively re-opens #499.