Search code examples
postman

Unable to Post a csv file in Postman, getting 400 error


I am trying to post a csv file and get the fields(fields in the csv file) in the response using Postman but I am getting 400 Bad request error. Error: { "status": 400, "error": "Bad Request", "message": "Required request part 'inFile' is not present", "timeStamp": "Tue Feb 07 00:00:17 EST 2017", "trace": "org.springframework.web.multipart.support.MissingServletRequestPartException: Required request part 'inFile' is not present\n\tat org.springframework.web.servlet.mvc.method.annotation.RequestPartMethodArgumentResolver.resolveArgument(RequestPartMethodArgumentResolver.java:192)\n\tat org.springframework.web.method.support.HandlerMethodArgumentResolverComposite....} Please let me know how to overcome this issue as I am new to this.

Form_Data_error


Solution

  • You forgot to give a name to your form-data parameter.

    According to the error you got the name of the key should be "inFile".

    And you need to input it here: enter image description here