Detecting Extra Fields in ASP.NET Web API Request

This post is related to binding in ASP.NET Web API. Binding (parameter binding, to be exact) is the mechanism through which request body is bound to the action method parameter. Say you are using a DTO class as parameter and if you want to ensure a field is present in the request, you can apply Required attribute at the property level like so.
Continue reading

Advertisements