pb33f / wiretap

The world's coolest API Validation and compliance tool. Validate APIs against OpenAPI specifications and much more
https://pb33f.io/wiretap/
Other
125 stars 18 forks source link

Feature : Restrictive / Lock down API specification #72

Open LasneF opened 11 months ago

LasneF commented 11 months ago

do you think it would be possible to kind of lock down the spec Kind of setting aditionnal Properties to false with a flag in wiretab command line

meanning given the spec "schema" : { "type" : "object", "properties" : { "message" : {"type" : "string"}, "who" : {"type" : "string"} }

if i send "message" : "Hello" , "who":"bob" , "offender":12 , Flag Off = it says green , FlagOn = it says red the topic beeing to spot that the server returns undocumented fields ...

daveshanley commented 11 months ago

I don't see why not. I would assume that the JSON schema lib we use would handle that, but if not, it's logic that can be added in to our lib.

LasneF commented 9 months ago

notice that redocly issue a warning for such use case and i think it is wise