I am trying to post a file from Postman to the endpoint I have created. but it gives me this error. I am not passing the header Content-Type in postman
Try using [FromForm] instead of [FromBody] for the method parameter if you're POSTing form data.
[FromForm]
[FromBody]