API Platform version(s) affected: 2.5.1
Description
Today, JSON Schemas generated by API-Platform do not include additionalProperties: false
. This reduces type saftey when using a code generator.
How to reproduce
Create an ApiResource in a new project, check the generated Swagger documentation. The JSON Schema generated for the ApiResource does not include additionalProperties: false
.
Possible Solution
Simply add additionalProperties: false
when generating the schema.