You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Validation of Media Type (Content-type) fails when a single letter is different from OpenApi document and the Request data.
In order to understand better what's going on, would be better to add to the error message which media types are allowed by the Open Api document.
The piece of code which has to change is:
src/OpenApiContract.Validator/RequestValidator.cs:170
if(!requestBodySpec.Content.TryGetValue(content.Headers.ContentType.MediaType,outOpenApiMediaTypemediaTypeSpec))thrownewRequestDoesNotMatchSpecException($"Content media type '{content.Headers.ContentType.MediaType}' is not specified");
The text was updated successfully, but these errors were encountered:
Validation of Media Type (Content-type) fails when a single letter is different from OpenApi document and the Request data.
In order to understand better what's going on, would be better to add to the error message which media types are allowed by the Open Api document.
The piece of code which has to change is:
src/OpenApiContract.Validator/RequestValidator.cs:170
The text was updated successfully, but these errors were encountered: