Description
Good afternoon. I am trying to use the /schema endpoint to retrieve the schema of a collection. While the endpoint returns a
valid JSON Schema, the "required" field of the schema is missing, making it incomplete. We rely on this functionality to validate a set of documents before deleting all documents in a collection and replacing them, but the supplied schema is not sufficient to correctly validate our documents before wiping the collection.
Environment
I'm using CRUD Service version 7.0.2
Minimal Reproduction
Given a crud-service instance with a collection books that has the required field name, the following curl
Description Good afternoon. I am trying to use the
/schema
endpoint to retrieve the schema of a collection. While the endpoint returns a valid JSON Schema, the "required" field of the schema is missing, making it incomplete. We rely on this functionality to validate a set of documents before deleting all documents in a collection and replacing them, but the supplied schema is not sufficient to correctly validate our documents before wiping the collection.Environment
I'm using CRUD Service version 7.0.2
Minimal Reproduction
Given a
crud-service
instance with a collectionbooks
that has the required fieldname
, the following curlreturns the following schema
However, the schema should be: